13 lines
303 B
Groovy
13 lines
303 B
Groovy
stage ('publish') {
|
|
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'
|
|
}
|
|
}
|
|
}
|