-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Enhancement] Import\configure project through compile_commands.json file #89
Comments
@pidgeon777 Currently CodeQuery is not using libclang, so it doesn't really need compilation commands and flags. cscope and ctags or similar tools only need a list of files. Nevertheless this can be considered a possible feature enhancement. I thought about writing a tool to use libclang as another frontend but I haven't got around to it yet. But I think it will be a lot slower than cscope and ctags. However, it will be more accurate. |
This is an example of [
{
"directory": "C:/Work/Projects/Linux/Programs/Hello_World",
"command": "C:/CrossComp/bin/aarch64-none-linux-gnu-gcc.exe -Wall -Wextra -I. -isystem C:/CrossComp/aarch64-none-linux-gnu/libc/usr/include -O3 -DNDEBUG -std=c99 -o main.o -c main.c",
"file": "C:/Work/Projects/Linux/Programs/Hello_World/main.c"
},
{
"directory": "XXX",
"command": "YYY",
"file": "ZZZ"
},
...
] The main key elements are:
To generate the This means that by parsing a
By doing so, a
and it would include exactly the same files parsed through the So, the resulting
This would be great and I encourage you to do so. Even better if it could work as an LSP client, thus compatible with almost every programming language. |
It would be great to be able to import in
codequery
all of the source files and project configuration through an already existingcompile_commands.json
file, which is already the core file of code indexers such asclang
orccls
and thus widely used in the most common projects.In fact, all of the necessary files, compilation commands and flags needed to fully parse, index and analyse a project, is described there.
An option in the GUI or command line could thus be provided so that a project is loaded by specifying the
compile_commands.json
file for that project, also shared byclang
and/orccls
.The text was updated successfully, but these errors were encountered: