@@ -18,7 +18,7 @@ $EnvDetectUseSnapshot = Get-EnvironmentVariable -Key "DETECT_USE_SNAPSHOT" -Defa
1818
1919# If you want to skip the test for java
2020# DETECT_SKIP_JAVA_TEST=1
21- $DetectSkipJavaTest = Get-EnvironmentVariable - Key " DETECT_SKIP_JAVA_TEST" - DefaultValue " " ;
21+ $EnvDetectSkipJavaTest = Get-EnvironmentVariable - Key " DETECT_SKIP_JAVA_TEST" - DefaultValue " " ;
2222
2323# If you do not want to exit with the detect exit code,
2424# set DETECT_EXIT_CODE_PASSTHRU to 1 and this script won't exit, but simply return it (pass it thru).
@@ -44,7 +44,7 @@ $EnvHomeTempFolder = "$HOME\tmp"
4444# heap size, you would set DETECT_JAVA_OPTS=-Xmx6G.
4545# $DetectJavaOpts = Get-EnvironmentVariable -Key "DETECT_JAVA_OPTS" -DefaultValue "";
4646
47- $Version = " 0.6.0 "
47+ $Version = " 0.6.2 "
4848
4949$DetectReleaseBaseUrl = " https://test-repo.blackducksoftware.com/artifactory/bds-integrations-release/com/blackducksoftware/integration/hub-detect"
5050$DetectSnapshotBaseUrl = " https://test-repo.blackducksoftware.com/artifactory/bds-integrations-snapshot/com/blackducksoftware/integration/hub-detect"
@@ -56,7 +56,7 @@ $DetectVersionUrl = "https://test-repo.blackducksoftware.com/artifactory/api/sea
5656function Detect {
5757 Write-Host " Detect Powershell Script $Version "
5858
59- if ($DetectSkipJavaTest -ne " 1" ){
59+ if ($EnvDetectSkipJavaTest -ne " 1" ){
6060 Test-JavaExists
6161 }else {
6262 Write-Host " Skipping java test."
@@ -124,7 +124,7 @@ function Get-ProxyInfo () {
124124 $ProxySecurePassword = ConvertTo-SecureString $ProxyPassword - AsPlainText - Force
125125 $ProxyCredentials = New-Object System.Management.Automation.PSCredential ($ProxyUsername , $ProxySecurePassword )
126126
127- $ProxyInfo .Credentials = $ProxyCredentials ;
127+ $ProxyInfoProperties .Credentials = $ProxyCredentials ;
128128 }
129129
130130 Write-Host " Succesfully setup proxy."
@@ -137,7 +137,7 @@ function Get-ProxyInfo () {
137137 Write-Host (" Reason: {0}" -f $_.Exception.StackTrace );
138138 }
139139
140- $ProxyInfo = New-Object – TypeName PSObject – Prop $ProxyInfoProperties
140+ $ProxyInfo = New-Object - TypeName PSObject - Prop $ProxyInfoProperties
141141
142142 return $ProxyInfo ;
143143}
@@ -206,7 +206,7 @@ function Get-DetectJar ($DetectFolder, $DetectVersion, $ProxyInfo) {
206206}
207207
208208function Invoke-Detect ($DetectJarFile , $DetectArgs ) {
209- ${Env: detect.phone.home.passthrough.powershell.version} = $Version
209+ ${Env: detect.phone.home.passthrough.powershell.version} = $Version
210210 $JavaArgs = @ (" -jar" , $DetectJarFile )
211211 $AllArgs = $JavaArgs + $DetectArgs
212212 Set-ToEscaped ($AllArgs )
0 commit comments