Skip to content

Fix xargs#4308

Open
rasapala wants to merge 1 commit into
mainfrom
fix_ci_xargs
Open

Fix xargs#4308
rasapala wants to merge 1 commit into
mainfrom
fix_ci_xargs

Conversation

@rasapala

@rasapala rasapala commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

🛠 Summary

Switch unix xargs prone to env tool settings errors on node windows setup to native powershell command.

🧪 Checklist

  • Unit tests added.
  • The documentation updated.
  • Change follows security best practices.
    ``

Copilot AI review requested due to automatic review settings June 22, 2026 10:07

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot couldn't run its full agentic review because no GitHub Actions runner was available. Make sure your repository has a runner available to run Copilot's review, or add a copilot-setup-steps.yml file specifying one with the runs-on attribute. See the docs for more details.

Updates the Windows CI unit test summary extraction to avoid reliance on xargs (and other Unix-like tools) by switching to a PowerShell-based approach.

Changes:

  • Replaced grep | head | cut | xargs | head pipeline with a single PowerShell command to extract the relevant portion of win_test_summary.log.

Comment thread ci/loadWin.groovy Outdated
def summaryContent
if (markerLine == 0) {
summaryContent = bat(returnStatus: false, returnStdout: true, script: '@grep -n "Check tests summary in" win_test_summary.log | head -1 | cut -d: -f1 | xargs -I{} head -{} win_test_summary.log').trim()
summaryContent = bat(returnStatus: false, returnStdout: true, script: '@powershell -NoProfile -Command "$content = Get-Content ''win_test_summary.log''; $marker = ($content | Select-String -SimpleMatch ''Check tests summary in'' | Select-Object -First 1).LineNumber; if ($marker) { $content[0..([Math]::Max(0, [int]$marker - 1))] -join [Environment]::NewLine } else { $content | Select-Object -First 150 | Out-String }"').trim()
Comment thread ci/loadWin.groovy Outdated
Comment thread ci/loadWin.groovy Outdated
Comment thread ci/loadWin.groovy Outdated
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.

3 participants