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

PowerShell subexpressions nested within strings #1757

Closed
thecityofguanyu opened this issue Oct 28, 2021 · 1 comment · Fixed by #1900
Closed

PowerShell subexpressions nested within strings #1757

thecityofguanyu opened this issue Oct 28, 2021 · 1 comment · Fixed by #1900
Labels
bugfix-request A request for a bugfix to be developed.

Comments

@thecityofguanyu
Copy link

thecityofguanyu commented Oct 28, 2021

Name of the lexer
PowerShell

Code sample
A sample of the code that produces the bug.

function Write-Log {
    Param(
        $Message,
        $Path = "L:\IISSiteAudit.txt"
    )

    function TS { return "[{0:MM/dd/yy} {0:HH:mm:ss}]" -f (Get-Date) }
    "$(TS) $Message" | Tee-Object -FilePath $Path -Append | Write-Verbose
}

Sample on rouge.jneen.net.

Additional context
Specifically, characters after the "$() get mangled as if they're all part of the string -- even after the closing " character.

Originally observed via GitLab 14.3.2. Re-produced locally with Rogue v3.26.1 via rougify,

@retryW
Copy link

retryW commented Sep 5, 2022

Has been an annoyance of mine in GitLab for some time and when I saw it still existed in 15.1 I started seeing if it was raised as an issue.

Would very much love to see some movement on this one :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix-request A request for a bugfix to be developed.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants