Skip to content

Commit fc1bc0b

Browse files
tomapJakeGinnivan
authored andcommitted
set verbosity following system.debug variable. See https://www.visualstudio.com/en-us/docs/build/define/variables
1 parent 26efb69 commit fc1bc0b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/GitVersionTfsTask/GitVersion.ps1

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,13 @@ if($additionalArguments)
5454
$argsGitVersion = $argsGitVersion + " $additionalArguments"
5555
}
5656

57+
if(!$additionalArguments -or !$additionalArguments.Contains("-debug"))
58+
{
59+
if([string]::IsNullOrEmpty($env:SYSTEM_DEBUG) -or $env:SYSTEM_DEBUG -ne "true"){
60+
$argsGitVersion = $argsGitVersion + " -verbosity Error"
61+
}
62+
}
63+
5764
Write-Host (Get-LocalizedString -Key "Invoking GitVersion with {0}" -ArgumentList $argsGitVersion)
5865

5966
Invoke-Tool -Path $GitVersionPath -Arguments "$argsGitVersion"

0 commit comments

Comments
 (0)