Skip to content

solve issue with running tool when there are spaces in its path#1988

Open
denisbredikhin wants to merge 6 commits intoGitTools:mainfrom
denisbredikhin:exec-fix
Open

solve issue with running tool when there are spaces in its path#1988
denisbredikhin wants to merge 6 commits intoGitTools:mainfrom
denisbredikhin:exec-fix

Conversation

@denisbredikhin
Copy link

Switch from child_process exec to execFile
Solves #1912

Copilot AI review requested due to automatic review settings March 10, 2026 13:49
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the build agent command execution helper to avoid Windows failures when the executable path contains spaces (as reported in #1912) by moving away from shell-based execution.

Changes:

  • Replace child_process.exec with child_process.execFile to execute binaries directly (avoids path/quoting issues).
  • Normalize stdout/stderr to strings for consistent ExecResult output.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@sonarqubecloud
Copy link

@arturcic arturcic self-assigned this Mar 10, 2026
@arturcic arturcic linked an issue Mar 13, 2026 that may be closed by this pull request
2 tasks
@arturcic
Copy link
Member

@denisbredikhin please rebase the pr onto main

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.

[ISSUE]: gitversion-execute@4.2.0 fails on Windows (with self hosted agent?)

4 participants