feat(clion): Add working directory to CLion Run configurations
Checklist
- [ ] I have filed an issue about this change and discussed potential changes with the maintainers.
- [X] I have received the approval from the maintainers to make this change.
- [X] This is not a stylistic, refactoring, or cleanup change.
Please note that the maintainers will not be reviewing this change until all checkboxes are ticked. See the Contributions section in the README for more details.
Discussion thread for this change
Issue number: N/A
Description of this change
In CMake CLion, one has the option of setting a working directory under which the binary will be run. This is useful for debugging single binaries (i.e. they need no runfiles) under different contexts.
This PR adds some of that capability to the Bazel plugin by creating a setting for run configurations, and adding it to the Cidr debug process handlers.
Limitations:
- For now, this only applies to CLion debugging configurations. Other debuggers will have to be modified to use the setting, as well as non-debug configurations.
- Previously, we defaulted to the runfiles dir as the pwd if there was one. The explicit working dir has precedence over it now.
My only concern is that there is a difference between debug and run result now. I know it's mentioned in checkbox's label, but still it may cause some annoyance
@sgowroji or @tpasternak, is there anything that can be done to help push this forwards?
I'll take a look at this one next week
@shs96c sorry for the delay. Would it be possible for you to just rebase the PR? I think it's ok.
@tpasternak, @blorente has left our team, and rather than bother him I've opened #6698 as a fresh version of this PR.