Commit Graph

2 Commits

Author SHA1 Message Date
Nikita Putikhin
7da179ef34 Add --vscode-launch-file to gdbclient.py
The new argument makes the generator write the VSCode launch.json config
into a file instead of stdout.

The generator uses marker lines to insert the config. This way the user
can control where in the file the launch config is written.

Test: atest gdbclient_test
Test: lldbclient.py --setup-forwarding vscode-lldb \
  --vscode-launch-props= \
  '{"internalConsoleOptions" : "openOnSessionStart"}' \
  --vscode-launch-file=.vscode/launch.json -r test

Change-Id: I92b3f479b5ebcb722933938f52d0f23ff098beac
2023-07-13 13:48:37 +00:00
Nikita Putikhin
9aa3bc65ba Add --vscode-launch-props to gdbclient.py
The new argument allows the user to pass a JSON of properties to merge
into the generated launch.json config when setting up vscode-lldb
forwarding. This way the user can add pre-build tasks, extra init
commands etc.

Test: atest gdbclient_test
Test: lldbclient.py --setup-forwarding=vscode-lldb
  --vscode-launch-props='{"sourceMap": {"test1": "test2"},
  "postDebugTask": "Stop LLDB client", "processCreateCommands" :
  ["test"]}' -r test
Change-Id: I763dd15dde10421e86bc0a6ddfde974156ef1588
2023-06-10 20:47:31 +00:00