Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sh syntax highlight breaks on "${*//\${/x}": everything after becomes shDoubleQuote or shDerefPPSleft #5085

chkno opened this issue Oct 18, 2019 · 0 comments


Copy link

@chkno chkno commented Oct 18, 2019

sh syntax highlighting treats \${ as introducing a parameter expansion when inside ${var// .... /}, but bash does not -- bash sees the \ as escaping the $. Both / (substitute first) and // (substitute all) are affected.

To Reproduce

  1. Edit this file with syntax highlighting on:

echo "${1//\${/dollar curly}"
echo "The rest of this file is shDerefPPSleft inside double quotes"
echo and shDoubleQuote _outside_ double quotes


Environment (please complete the following information):

Additional context
Maintainer: @cecamp

@k-takata k-takata added the runtime label Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.