microsoft / microsoft/vscode-cpptools

Nicer workflow for GDB+attach

Open
#7,830 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

debugger more info needed
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

Type: Feature Request

I have a Python program that repeatedly compiles C++ code as a shared library, and launches it in a forked process.

The C++ code is run as soon as GDB is attached. I detect this by waiting for SIGUSR1.

In VSCode, I have to press F5, then F6, then Ctrl-Shift-Y, then type "-exec signal SIGUSR1". It would be nice if that sequence of actions could be automatically triggered via launch.json.

Unfortunately, "stopAtConnect" is not working, and neither is

"setupCommands": [
  {
      "text": "-interpreter-exec console \"signal SIGUSR1\"",
  }
]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the reported F5, F6, and Ctrl-Shift-Y sequence with the GDB attach configuration in launch.json, focusing on stopAtConnect and setupCommands. Compare the configured behavior with manually running -exec signal SIGUSR1; done means the sequence can be triggered through launch.json and the C++ code starts after attachment.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, vscode
Domain
devtools
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.