-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Low
-
None
-
Affects Version/s: 2.6.10
-
Component/s: None
-
Severity 1 - Critical
I'm trying to create a custom action that runs a PowerShell script but am unable to run it because SourceTree is surrounding the parameters with additional quotation marks which break the script.
Here is the custom action I've defined:
Script to run: powershell.exe
Parameters: -NonInteractive -NoProfile -File "C:\path\to\script.ps1" -RepoPath "$REPO" -Commit "$SHA"
And here is what is executed by SourceTree when I run this custom action:
powershell.exe "-NonInteractive -NoProfile -File "C:\path\to\script.ps1" -RepoPath "C:\c\wbsdk" -Commit "cebbfebd23b61bdae80a3505c00e7d7592e2ead1""
Note that SourceTree has added a quote at the start and end of my parameters which causes PowerShell to fail to parse the parameters as intended.
- duplicates
-
SRCTREE-6355 Custom Action: Multiple parameters get quoted together incorrectly
-
- Closed
-
-
SRCTREE-6115 Custom Action: Quotes in Parameters: Everything gets quoted
-
- Closed
-