File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -337,12 +337,15 @@ export default class PublishAction extends CommandLineAction {
337337 const args : string [ ] = [ 'publish' ] ;
338338
339339 if ( this . _rushConfiguration . projectsByName . get ( packageName ) . shouldPublish ) {
340+ let registry : string = '//registry.npmjs.org/' ;
340341 if ( this . _registryUrl . value ) {
341- env [ 'npm_config_registry' ] = this . _registryUrl . value ; // tslint:disable-line:no-string-literal
342+ const registryUrl : string = this . _registryUrl . value ;
343+ env [ 'npm_config_registry' ] = registryUrl ; // tslint:disable-line:no-string-literal
344+ registry = registryUrl . substring ( registryUrl . indexOf ( '//' ) ) ;
342345 }
343346
344347 if ( this . _npmAuthToken . value ) {
345- args . push ( `--// registry.npmjs.org/ :_authToken=${ this . _npmAuthToken . value } ` ) ;
348+ args . push ( `--${ registry } :_authToken=${ this . _npmAuthToken . value } ` ) ;
346349 }
347350
348351 if ( this . _force . value ) {
You can’t perform that action at this time.
0 commit comments