fix: add -Encoding ASCII to Set-Content to prevent npm auth BOM issue
这个提交包含在:
父节点
e9b3a39ae0
当前提交
a68550e576
2
Jenkinsfile
vendored
2
Jenkinsfile
vendored
@ -68,7 +68,7 @@ pipeline {
|
||||
steps {
|
||||
withCredentials([usernamePassword(credentialsId: 'NEXUS_CREDS', passwordVariable: 'NPM_PASS', usernameVariable: 'NPM_USER')]) {
|
||||
bat """
|
||||
powershell -NonInteractive -Command "Set-Content .npmrc ('//nexus.xuqinmin.com/repository/npm-hosted/:_auth=' + [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(\$env:NPM_USER + ':' + \$env:NPM_PASS)))"
|
||||
powershell -NonInteractive -Command "Set-Content .npmrc ('//nexus.xuqinmin.com/repository/npm-hosted/:_auth=' + [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(\$env:NPM_USER + ':' + \$env:NPM_PASS))) -Encoding ASCII"
|
||||
npm publish --registry %NEXUS_REGISTRY%
|
||||
"""
|
||||
}
|
||||
|
||||
正在加载...
在新工单中引用
屏蔽一个用户