-
Notifications
You must be signed in to change notification settings - Fork 38.2k
Description
I haven't checked the code who renders this part, but I'd believe this is only a visual bug, aside from maybe creating rickroll/phishing links.
For what I could skim from the visual representation, the terminal tab popup's "Shell Integration" section renders the command text by wrapping it with backticks:
`echo like this;`However, it is possible to use backticks in a valid command, which breaks this wrapping
apt install --only-upgrade `grep 'dev' ./apt-dependencies.lock`(the code doesn't matter, using backticks matters)
Since the command has a backtick, this breaks the wrapping:
`apt install --only-upgrade `grep 'dev' ./apt-dependencies.lock``Does this issue occur when all extensions are disabled?: Will test later as it's a remote machine right now.
- VS Code Version: 1.105.1 (user setup)
- OS Version: Windows_NT x64 10.0.19045
Steps to Reproduce:
- Run a long running command with backticks (```) from terminal
- Hover over the terminal icon in the Terminal View.
- The text is not escaped, which breaks the backtick.
P.S: I might be able to make a PR in a few days if the issue really happens to be simple.
Changing the wrapping to a <pre> could fix it...
and then escaping the < and > with < and > to make sure the command can't break by having html in the command text...
I'm open to comments!