Skip to content

Suggest valid target keys for common typos - #202

Merged
mrexodia merged 2 commits into
build-cpp:mainfrom
aouxwoux:agent/suggest-target-key
Aug 22, 2026
Merged

Suggest valid target keys for common typos#202
mrexodia merged 2 commits into
build-cpp:mainfrom
aouxwoux:agent/suggest-target-key

Conversation

@aouxwoux

@aouxwoux aouxwoux commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

what changed

when someone writes link-flags, compile-flags, or flags, cmkr now suggests the config key that actually exists.

the suggestion is only shown when that key is valid for the current target type.

why

these are pretty natural names to try, and the old error did not give much to go on.

checks

  • git diff --check passes.
  • github ci passed on the previous revision; the amended commit will rerun it.
  • the local machine does not have cmake, ninja, or a c++ compiler installed.

fixes #134

@aouxwoux
aouxwoux force-pushed the agent/suggest-target-key branch from bb23a7f to e71102a Compare August 2, 2026 15:33
@aouxwoux
aouxwoux force-pushed the agent/suggest-target-key branch from e71102a to 488b646 Compare August 2, 2026 15:42
@aouxwoux
aouxwoux marked this pull request as ready for review August 2, 2026 16:35
@mrexodia

mrexodia commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

I think it's a good start, but I think a levenshtein distance between existing keys could also help. For example if you type cmpile-flags it would suggest compile-flags

@mrexodia
mrexodia merged commit 7627d49 into build-cpp:main Aug 22, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Suggestions for non-existent link-flags or compile-flags or flags target keys

2 participants