diff options
-rw-r--r-- | .dir-locals.el | 6 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | build.sh | 9 | ||||
-rw-r--r-- | main.c | 30 |
4 files changed, 46 insertions, 0 deletions
diff --git a/.dir-locals.el b/.dir-locals.el new file mode 100644 index 0000000..d7eba5e --- /dev/null +++ b/.dir-locals.el @@ -0,0 +1,6 @@ +;;; Directory Local Variables -*- no-byte-compile: t -*- +;;; For more information see (info "(emacs) Directory Variables") + +((nil . ((compile-command . "sh build.sh && ./flock.out") + (+license/license-choice . "Unlicense"))) + (c-mode . ((mode . clang-format)))) diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..645913e --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/flock.out diff --git a/build.sh b/build.sh new file mode 100644 index 0000000..2d075a7 --- /dev/null +++ b/build.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env sh + +CFLAGS="-Wall -Wextra -fsanitize=address -fsanitize=undefined -std=c11 -ggdb -lraylib" +SRC="main.c" +OUT="flock.out" + +set -xe + +cc $CFLAGS -o $OUT $SRC; @@ -0,0 +1,30 @@ +/* Copyright (C) 2025 Aryadev Chavali + + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the Unlicense for details. + + * You may distribute and modify this code under the terms of the Unlicense, + * which you should have received a copy of along with this program. If not, + * please go to <https://unlicense.org/>. + + * Created: 2025-06-03 + * Description: + */ + +#include <raylib.h> +#include <stdio.h> + +int main(void) +{ + InitWindow(800, 600, "Flock Simulation"); + while (!WindowShouldClose()) + { + BeginDrawing(); + ClearBackground(BLACK); + DrawText("Hello, world!", 360, 260, 20, WHITE); + EndDrawing(); + } + CloseWindow(); + return 0; +} |