diff --git a/lib/authutil.js b/lib/authutil.js index 51bb92a1..e5a8e2b1 100644 --- a/lib/authutil.js +++ b/lib/authutil.js @@ -45,9 +45,9 @@ function writeRegistryToFile(registryUrl, fileLocation) { const registryString = scope ? `${scope}:registry=${registryUrl}` : `registry=${registryUrl}`; - newContents += `${registryString}${os.EOL}${authString}`; + newContents += `${authString}${os.EOL}${registryString}`; fs.writeFileSync(fileLocation, newContents); -// core.exportVariable('NPM_CONFIG_USERCONFIG', fileLocation); + // core.exportVariable('NPM_CONFIG_USERCONFIG', fileLocation); // Export empty node_auth_token so npm doesn't complain about not being able to find it // core.exportVariable('NODE_AUTH_TOKEN', 'XXXXX-XXXXX-XXXXX-XXXXX'); } diff --git a/src/authutil.ts b/src/authutil.ts index cb6bd6a2..f4965590 100644 --- a/src/authutil.ts +++ b/src/authutil.ts @@ -40,7 +40,7 @@ function writeRegistryToFile(registryUrl: string, fileLocation: string) { const registryString = scope ? `${scope}:registry=${registryUrl}` : `registry=${registryUrl}`; - newContents += `${registryString}${os.EOL}${authString}`; + newContents += `${authString}${os.EOL}${registryString}`; fs.writeFileSync(fileLocation, newContents); // core.exportVariable('NPM_CONFIG_USERCONFIG', fileLocation); // Export empty node_auth_token so npm doesn't complain about not being able to find it