Skip to content

Fix PowerShell backtick escaping in CodeQL workflow summary step#33

Merged
daxgames merged 2 commits intomainfrom
copilot/fix-commit-issue
Feb 22, 2026
Merged

Fix PowerShell backtick escaping in CodeQL workflow summary step#33
daxgames merged 2 commits intomainfrom
copilot/fix-commit-issue

Conversation

Copy link

Copilot AI commented Feb 21, 2026

The Analyze (cpp) CodeQL job was failing on the "Summary - Analysis completed" step due to a PowerShell string escaping bug.

Root Cause

In PowerShell, backtick (`) is the escape character. The line:

echo "**Language analyzed:** `${{ matrix.language }}`" >> $env:GITHUB_STEP_SUMMARY

After GHA expands ${{ matrix.language }}cpp, PowerShell receives:

echo "**Language analyzed:** `cpp`" >> $env:GITHUB_STEP_SUMMARY

The trailing `" escapes the closing double-quote, leaving the string unterminated → parse error → step failure.

Fix

Use `` (PowerShell's escaped backtick) instead of a bare `:

echo "**Language analyzed:** ``${{ matrix.language }}``" >> $env:GITHUB_STEP_SUMMARY
Original prompt

Reference: https://github.com/daxgames/cmder/commit/33f88b6348ea59eb688f56b7e7a671f4282960f9/checks?check_suite_id=58138001594

fix this


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: daxgames <7318053+daxgames@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix issue with commit in the project Fix PowerShell backtick escaping in CodeQL workflow summary step Feb 21, 2026
Copilot AI requested a review from daxgames February 21, 2026 23:59
@daxgames daxgames marked this pull request as ready for review February 22, 2026 00:18
@daxgames daxgames merged commit f5746c1 into main Feb 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants