Add sb_read_file()

This commit is contained in:
kamkow1
2025-06-01 23:34:31 +02:00
parent 0ce4a1018e
commit 5724c8ffa8
3 changed files with 59 additions and 4 deletions

17
example/sb.c Normal file
View File

@ -0,0 +1,17 @@
#define GEBS_NO_PREFIX
#define GEBS_IMPLEMENTATION
#include "../gebs.h"
int main(int argc, char ** argv)
{
String_Builder sb_c;
if (!sb_read_file(&sb_c, "sb.c")) {
LOGE("Could not read sb.c. sb.c is in example/\n");
return 1;
}
sb_finish(&sb_c);
printf("%s\n", sb_c.items);
return 0;
}