From c28caef03809d0bd727916a10b6ea47d35688eab Mon Sep 17 00:00:00 2001 From: Seth Hamilton Date: Sun, 7 Sep 2025 13:24:11 -0500 Subject: [PATCH] work on compile commands bash file --- export_compile_commands.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 export_compile_commands.sh diff --git a/export_compile_commands.sh b/export_compile_commands.sh new file mode 100644 index 0000000..540ef1f --- /dev/null +++ b/export_compile_commands.sh @@ -0,0 +1,12 @@ +srcs=src/* +working_dir=$pwd +command_pre="cl" +command_post="-I inc -Od -std:c++20 -Fo" + +echo [ > compile_commands.json + +find src -iname "*.cpp" -o -iname "*.c" -exec sh -c 'echo { "directory": "$(pwd)", "command": "$(command_pre) {} $(command_pos)", "file": "{}" }, >> compile_commands.json' \; + +echo ] >> compile_commands.json + +# axiomatic,