jenkins-scripts/publish/Jenkinsfile

13 lines
303 B
Plaintext
Raw Normal View History

2020-03-02 22:35:26 +03:00
stage ('publish') {
2020-03-02 22:47:41 +03:00
echo 'checking tag'
script {
def tag = sh(returnStdout: true, script: "git tag --contains").trim()
if (tag) {
echo 'found tag ' + tag
sh 'npm publish --access public'
} else {
echo 'tag not found'
2020-03-02 22:35:26 +03:00
}
}
}