Restructure project, add gebs_exists() and gebs_mkdir()

This commit is contained in:
kamkow1
2025-05-19 12:25:08 +02:00
parent 0087c523b5
commit c905379d14
6 changed files with 45 additions and 14 deletions

3
example/.gitignore vendored
View File

@ -1,3 +0,0 @@
gebs
a.out
main

View File

@ -1,13 +0,0 @@
#define GEBS_IMPLEMENTATION
#include "../gebs.h"
int main(int argc, char ** argv)
{
gebs_rebuild_self(argc, argv, "cc", "-o", "gebs", __FILE__);
if (GEBS_CMD("gcc", "-o", "main", "main.c") != 0) {
return 1;
}
return 0;
}

View File

@ -1,7 +0,0 @@
#include <stdio.h>
int main(void)
{
printf("Hello world\n");
return 0;
}

11
example/self_rebuild.c Normal file
View File

@ -0,0 +1,11 @@
#include <stdio.h>
#define GEBS_IMPLEMENTATION
#include "../gebs.h"
int main(int argc, char ** argv)
{
gebs_rebuild_self(argc, argv, "cc", "-o", "self_rebuild", __FILE__);
printf("Hello world\n");
return 0;
}