coding-webhook-plugin
coding-webhook-plugin copied to clipboard
env.BRANCH_NAME返回的是null
不确定这个问题是出在Coding plugin上还是Jenkins上,先描述一下问题吧:
弄了一个Simple Pipeline项目。
在Jenkinsfile里通过全局变量${env.BRANCH_NAME}得到的结果是null。
不过在这个界面是能够看到当前构建分支的:
因为我有这么一个要求,develop分支的打包推送到nexus仓库,其他分支不推送,如果无法知道当前是什么分支就没有办法达到这个要求了。