Skip to content

Commit 699ff4c

Browse files
Fix release scripts
1 parent 649126a commit 699ff4c

File tree

1 file changed

+5
-17
lines changed

1 file changed

+5
-17
lines changed

JenkinsfileRelease

Lines changed: 5 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@ properties([
22
gitLabConnection('gitlab')
33
])
44

5+
parameters {
6+
string(name: 'SDK_VERSION', defaultValue: 'v2310.0.0', description: 'version of sdk')
7+
}
8+
59
node('win2019') {
6-
try {
7-
env.SDK_VERSION = powershell(returnStdout: true, script:'$re = (ConvertFrom-Json -InputObject (New-Object System.Net.WebClient).DownloadString("https://api.aspose.cloud/v4.0/words/swagger/spec")).info.version -match "^(\\d+)\\.(\\d+)"; $version = $matches[1] + ("{0:d2}" -f [int]$matches[2]); echo ("v" + $version + ".0.0")').trim()
8-
10+
try {
911
gitlabCommitStatus("checkout") {
1012
stage('checkout'){
1113
checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'LocalBranch', localBranch: "**"]], submoduleCfg: [], userRemoteConfigs: [[credentialsId: '361885ba-9425-4230-950e-0af201d90547', url: 'https://git.auckland.dynabic.com/words-cloud/words-cloud-go.git']]])
@@ -40,20 +42,6 @@ node('win2019') {
4042
}
4143
}
4244
}
43-
44-
gitlabCommitStatus("announce a package") {
45-
stage('announce a package') {
46-
try {
47-
env.SHORT_SDK_VERSION = powershell(returnStdout: true, script:'echo $env:SDK_VERSION.Substring(0,5)').trim()
48-
powershell "Start-Sleep -Seconds 120"
49-
powershell 'echo (New-Object System.Net.WebClient).DownloadString("https://proxy.golang.org/github.com/aspose-words-cloud/aspose-words-cloud-go/$env:SHORT_SDK_VERSION/@v/$env:SDK_VERSION"+".info")'
50-
}
51-
catch(e)
52-
{
53-
echo 'Announcing error: ' + e.toString()
54-
}
55-
}
56-
}
5745
} finally {
5846
deleteDir()
5947
}

0 commit comments

Comments
 (0)