Skip to content

Commit 493d910

Browse files
committed
update script and rename folder from Scripts to scripts
1 parent 6b70c19 commit 493d910

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Scripts/validateMavenVersion.ps1

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,14 @@ $bintrayAPIurl = "https://api.bintray.com/search/packages?name=$packageName"
4343
$jsonResult = $web_client.DownloadString($bintrayAPIurl) | ConvertFrom-Json
4444
$bintrayVersion = [version]$jsonResult.latest_version
4545

46+
#If the api calls return empty then this library cannot be compared to the online versions
47+
#may proceed with the pull request
48+
if(($mavenVersion -eq $null) -and ($bintrayVersion -eq $null))
49+
{
50+
Write-Information "This package does not exist yet in the online repository, therefore there are no versions to compare."
51+
return
52+
}
53+
4654
#Inform host of current Maven and Bintray versions
4755
write-host 'The current version in the Maven central repository is:' $mavenVersion
4856
write-host 'The current version in the Bintray central repository is:' $bintrayVersion

0 commit comments

Comments
 (0)