Skip to content

Commit

Permalink
[phreeqc3] Fixed for major.minor (ie 3.8) build on
Browse files Browse the repository at this point in the history
windows
  • Loading branch information
scharlton2 committed May 21, 2024
1 parent 30e8744 commit 7502cda
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions jenkins-dist-build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,14 @@ $Env:RELEASE_DATE = date -d $Env:DATE "+%B %e, %G"
#
if ([string]::IsNullOrEmpty($Env:VER)) {
$request = Invoke-WebRequest https://raw.githubusercontent.com/usgs-coupled/phreeqc-version/main/phreeqc-version.txt -UseBasicParsing
$v = ($request.Content) -split "\."
$v = ($request.Content.Trim()) -split "\."
if ([string]::IsNullOrEmpty($v[2])) {
$v[2] = 0
# append a new element to the array
$v += 0
}
else {
$v[2] = 1 + $v[2]
}
$v[2] = 1 + $v[2]
$Env:ver_major = $v[0]
$Env:ver_minor = $v[1]
$Env:ver_patch = $v[2]
Expand Down

0 comments on commit 7502cda

Please # to comment.