Skip to content

Commit

Permalink
Merge pull request hyperledger-archives#1553 from Artemkaaas/feature/…
Browse files Browse the repository at this point in the history
…cli-dependency

IS-1139:  Updated CLI to depend on strict libindy version
  • Loading branch information
jovfer authored Mar 22, 2019
2 parents f612dc8 + 483569f commit 1ee29c7
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions Jenkinsfile.cd
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ def ubuntuPublishing() {
libvcxDebPublishing(testEnv)
vcxJavaWrapperPublishing(testEnv, false)
pythonWrapperPublishing(testEnv, false, 'vcx/wrappers/python3', 'vcx/libvcx')
nodejsWrapperPublishing(testEnv, false,'vcx')
nodejsWrapperPublishing(testEnv, false, 'vcx')
}
finally {
echo 'Publish Ubuntu files: Cleanup'
Expand Down Expand Up @@ -1069,6 +1069,8 @@ def libindyDebPublishing(testEnv, version) {
def libindyCliDebPublishing(testEnv, version) {
echo 'Publish Indy Cli deb files to Apt'

setLibindyDependencyVersion("cli/debian/control")

debPublishing(testEnv, "cli", "indy-cli", version, "IndyCliUbuntuBuildResult", "libindyCliDebs")
}

Expand All @@ -1077,6 +1079,8 @@ def libnullpayDebPublishing(testEnv) {

def libnullpayVersion = getSrcVersion("libnullpay")

setLibindyDependencyVersion("libnullpay/debian/control")

debPublishing(testEnv, "libnullpay", "libnullpay", libnullpayVersion, "LibnullpayUbuntuBuildResult", "libnullpayDebs")
}

Expand All @@ -1085,11 +1089,16 @@ def libvcxDebPublishing(testEnv) {

def libvcxVersion = getSrcVersion("vcx/libvcx")

setLibindyDependencyVersion("vcx/libvcx/debian/control")

debPublishing(testEnv, "vcx/libvcx", "libvcx", libvcxVersion, "LibvcxUbuntuBuildResult", "libvcxDebs")
}

def setLibindyDependencyVersion(file) {
def libindyVersion = getSrcVersion("libindy")
def replaceVersion = "$libindyVersion~$env.BUILD_NUMBER"
sh "sed -i -e \"s/^\\(Depends: .*libindy\\)\\(\\s*[,]\\{,1\\}.*\\)/\\1 (= $replaceVersion)\\2/\" vcx/libvcx/debian/control"

debPublishing(testEnv, "vcx/libvcx", "libvcx", libvcxVersion, "LibvcxUbuntuBuildResult", "libvcxDebs")
sh "sed -i -e \"s/^\\(Depends: .*libindy\\)\\(\\s*[,]\\{,1\\}.*\\)/\\1 (= $replaceVersion)\\2/\" $file"
}

def debPublishing(testEnv, directory, packageName, version, inStashName, outStashName) {
Expand Down Expand Up @@ -1155,7 +1164,7 @@ def npmPublish(version, suffix, directory) {
withCredentials([file(credentialsId: 'npm_credentials', variable: 'credentialsFile')]) {
sh 'cp $credentialsFile ~/.npmrc'
sh "cd $directory && " +
"npm version --no-git-tag-version --allow-same-version $version$suffix &&" +
"npm version --no-git-tag-version --allow-same-version $version$suffix &&" +
"npm publish"
}
}
Expand Down

0 comments on commit 1ee29c7

Please sign in to comment.