Skip to content

Add output_dir parameter to refresh_compile_commands - #13

Merged
helly25 merged 1 commit into
mainfrom
backport/210-output-dir
May 17, 2026
Merged

Add output_dir parameter to refresh_compile_commands#13
helly25 merged 1 commit into
mainfrom
backport/210-output-dir

Conversation

@helly25

@helly25 helly25 commented May 17, 2026

Copy link
Copy Markdown
Owner

Summary

New macro/rule parameter output_dir (default "" == workspace root, matching the historical behaviour). When set, both the pre-write unlink and the open() target are rerouted to <output_dir>/compile_commands.json.

Useful when you want compile_commands.json in a subdirectory (e.g. build/) rather than the workspace root.

Upstream context

Backport of hedronvision#210 (ilev4ik), adapted to coexist with our backport of #193: the unlink-before-write call also honours output_dir.

Test plan

  • Default args: compile_commands.json continues to land in workspace root
  • output_dir = "build": file lands in build/compile_commands.json

…itten

New macro/rule parameter `output_dir` (default empty == workspace root,
matching the historical behaviour). When set, both the pre-write unlink
and the open() target are rerouted to `<output_dir>/compile_commands.json`.

Backport of hedronvision#210 (ilev4ik).
@ilev4ik

ilev4ik commented May 19, 2026

Copy link
Copy Markdown

thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants