microsoft / microsoft/vscode-cmake-tools
Simplify selection of target - arguments - debug/launch
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.7k
- Forks
- 546
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 32
Description
Brief Issue Summary
I find it very cumbersome to make sense of the way cmake tools needs to be configured to execute targets.
On one hand you can use launch.json, but then you can't specify wheather to run the debugger or not. You can just pick a config and it automatically runs the debugger from the dropdown window.
On the other hand, if you don't use launch json and just launch via the debug/run buttons, it won't be possible to specify command line parameters for the target - except if you also configure "cmake.debugConfig" in your settings.json, but this statically allows just one entry, what if you have targets that require differnt command line arguments? It's an unnecessary duplication of what we have in launch.json already.
So my suggestion is to just simplify the whole thing. Usually you just need to pick 1) a target, 2) how it is executed and 3) wheather to run it in debug or nomal mode.
I'd add a target selection dropdown, then a dropdown to pick the launch.json entry ( which will pick up on the target anyway if "${command:cmake.launchTargetPath}" is used). And then have a run-debug and normal run button. Why is it so unnecessarily cumbersome right now? This question also ties into this.
CMake Tools Diagnostics
No response
Debug Log
No response
Additional Information
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing how launch.json, settings.json, and cmake.debugConfig currently drive the debug and run buttons, along with the target-selection UI. Compare that behavior with the linked discussion and define the target, launch configuration, and run-versus-debug flow described here. Done means users can select a target, choose a launch.json entry, and run normally or under the debugger without duplicating arguments.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cmake, vscode
- Domain
- developer-experience
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100