{"_id":"npm-cli-login","_rev":"2942749","name":"npm-cli-login","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","dist-tags":{"latest":"1.0.0"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"time":{"modified":"2023-04-21T09:34:52.000Z","created":"2016-02-16T10:14:27.234Z","0.1.1":"2019-01-26T07:07:59.556Z","1.0.0":"2021-10-22T21:40:31.769Z","0.0.10":"2016-03-16T10:19:48.043Z","0.0.7":"2016-03-02T07:39:51.739Z","0.0.6":"2016-02-17T14:05:17.579Z","0.0.5":"2016-02-17T13:32:26.862Z","0.0.2":"2016-02-16T10:14:27.234Z","0.0.3":"2016-02-16T10:50:12.602Z"},"users":{},"author":{"name":"Postman Team","email":"help@getpostman.com"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"versions":{"0.1.1":{"name":"npm-cli-login","version":"0.1.1","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/npm-cli-login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"scripts":{"test":"./scripts/test.sh","snyk-protect":"snyk protect","prepare":"npm run snyk-protect"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"8.6.0","snyk":"^1.91.0"},"devDependencies":{"chai":"^3.5.0","jscs":"^3.0.7","jshint":"^2.9.1","mocha":"^5.2.0"},"snyk":true,"gitHead":"0faae61c165559a6c78abb2d57482432b00851ca","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.1.1","_npmVersion":"6.4.1","_nodeVersion":"10.15.0","_npmUser":{"name":"czardoz","email":"aniketpanse@gmail.com"},"dist":{"shasum":"12e5bebc753cf433a3edab75be1d76f696c6fb86","size":6127,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.1.1.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/npm-cli-login_0.1.1_1548486479425_0.7857559659284374"},"_hasShrinkwrap":false,"publish_time":1548486479556,"_cnpm_publish_time":1548486479556,"_cnpmcore_publish_time":"2021-12-16T11:51:35.665Z"},"1.0.0":{"name":"npm-cli-login","version":"1.0.0","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","main":"index.js","bin":{"npm-cli-login":"bin/npm-cli-login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"scripts":{"test":"./scripts/test.sh","snyk-protect":"snyk protect","prepare":"npm run snyk-protect"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"8.6.0","snyk":"^1.124.1"},"devDependencies":{"chai":"^3.5.0","jscs":"^3.0.7","jshint":"^2.9.1","mocha":"^5.2.0"},"snyk":true,"gitHead":"8ab0f7457bbcb410ddb13251cc35e934078cb24c","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@1.0.0","_nodeVersion":"14.17.1","_npmVersion":"6.14.13","_npmUser":{"name":"jviotti","email":"jv@jviotti.com"},"dist":{"shasum":"a0682430c7efb7a8d37636303e8dfbc208c6d356","size":6176,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-1.0.0.tgz"},"directories":{},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/npm-cli-login_1.0.0_1634938831620_0.19564623083508326"},"_hasShrinkwrap":false,"publish_time":1634938831769,"_cnpm_publish_time":1634938831769,"_cnpmcore_publish_time":"2021-12-16T11:51:35.389Z"},"0.0.10":{"name":"npm-cli-login","version":"0.0.10","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/npm-cli-login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"scripts":{"test":"./scripts/test.sh"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"7.0.9"},"devDependencies":{"chai":"^3.5.0","jscs":"^2.10.1","jshint":"^2.9.1","mocha":"^2.4.5"},"gitHead":"408e2c2a5f3cead443a0eac4bbe43e001561854c","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.0.10","_shasum":"b1e8b5b7405008e0a26ccc170443434a59c5364c","_from":".","_npmVersion":"2.11.2","_nodeVersion":"4.1.1","_npmUser":{"name":"madebysid","email":"me@madebysid.com"},"dist":{"shasum":"b1e8b5b7405008e0a26ccc170443434a59c5364c","size":6097,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.0.10.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.0.10.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"packages-13-west.internal.npmjs.com","tmp":"tmp/npm-cli-login-0.0.10.tgz_1458123587469_0.8180665720719844"},"directories":{},"publish_time":1458123588043,"_hasShrinkwrap":false,"_cnpm_publish_time":1458123588043,"_cnpmcore_publish_time":"2021-12-16T11:51:36.017Z"},"0.0.7":{"name":"npm-cli-login","version":"0.0.7","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/npm-cli-login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"scripts":{"test":"./scripts/test.sh"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"7.0.9"},"devDependencies":{"jscs":"^2.10.1","jshint":"^2.9.1"},"gitHead":"c181132a8dfbd5844e6a484942286ede80425930","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.0.7","_shasum":"bdba217717714ab6a26e68e9fd9d47cbbecaa6bf","_from":".","_npmVersion":"2.11.2","_nodeVersion":"4.1.1","_npmUser":{"name":"madebysid","email":"me@madebysid.com"},"dist":{"shasum":"bdba217717714ab6a26e68e9fd9d47cbbecaa6bf","size":4439,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.0.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.0.7.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/npm-cli-login-0.0.7.tgz_1456904391222_0.2831932120025158"},"directories":{},"publish_time":1456904391739,"_hasShrinkwrap":false,"_cnpm_publish_time":1456904391739,"_cnpmcore_publish_time":"2021-12-16T11:51:36.238Z"},"0.0.6":{"name":"npm-cli-login","version":"0.0.6","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/npm-cli-login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"scripts":{"test":"./scripts/test.sh"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"7.0.9"},"devDependencies":{"jscs":"^2.10.1","jshint":"^2.9.1"},"gitHead":"ae2f20c3980c428931d56320e0acfe0962a286f8","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.0.6","_shasum":"c00ef9ba9c97b5a8192999c9329cd0beb0c96afe","_from":".","_npmVersion":"2.11.2","_nodeVersion":"4.1.1","_npmUser":{"name":"madebysid","email":"me@madebysid.com"},"dist":{"shasum":"c00ef9ba9c97b5a8192999c9329cd0beb0c96afe","size":4380,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.0.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.0.6.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"packages-9-west.internal.npmjs.com","tmp":"tmp/npm-cli-login-0.0.6.tgz_1455717915071_0.05086182267405093"},"directories":{},"publish_time":1455717917579,"_hasShrinkwrap":false,"_cnpm_publish_time":1455717917579,"_cnpmcore_publish_time":"2021-12-16T11:51:36.452Z"},"0.0.5":{"name":"npm-cli-login","version":"0.0.5","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates/modifies entries in the ~/.npmrc file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"scripts":{"test":"./scripts/test.sh"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"7.0.9"},"devDependencies":{"jscs":"^2.10.1","jshint":"^2.9.1"},"gitHead":"98d903550b9e74dd161ff01043bb40d8b217d91f","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.0.5","_shasum":"ce584b2805db9fe8614a1d08f98d82fa362e5802","_from":".","_npmVersion":"2.11.2","_nodeVersion":"4.1.1","_npmUser":{"name":"madebysid","email":"me@madebysid.com"},"dist":{"shasum":"ce584b2805db9fe8614a1d08f98d82fa362e5802","size":4380,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.0.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.0.5.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"packages-6-west.internal.npmjs.com","tmp":"tmp/npm-cli-login-0.0.5.tgz_1455715944737_0.7871088671963662"},"directories":{},"publish_time":1455715946862,"_hasShrinkwrap":false,"_cnpm_publish_time":1455715946862,"_cnpmcore_publish_time":"2021-12-16T11:51:36.674Z"},"0.0.2":{"name":"npm-cli-login","version":"0.0.2","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates entries in the ```~/.npmrc``` file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"7.0.9"},"gitHead":"654829a618630c0ba0c5815791cabbf0e11c1168","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.0.2","scripts":{},"_shasum":"8252b61e026b42c396608056c97d88a8fa78450a","_from":".","_npmVersion":"2.11.2","_nodeVersion":"4.1.1","_npmUser":{"name":"madebysid","email":"me@madebysid.com"},"dist":{"shasum":"8252b61e026b42c396608056c97d88a8fa78450a","size":1557,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.0.2.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"packages-5-east.internal.npmjs.com","tmp":"tmp/npm-cli-login-0.0.2.tgz_1455617663807_0.3939915362279862"},"directories":{},"publish_time":1455617667234,"_hasShrinkwrap":false,"_cnpm_publish_time":1455617667234,"_cnpmcore_publish_time":"2021-12-16T11:51:37.170Z"},"0.0.3":{"name":"npm-cli-login","version":"0.0.3","description":"Allows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems. Also creates entries in the ```~/.npmrc``` file for authentication.","main":"index.js","bin":{"npm-cli-login":"./bin/login.js"},"repository":{"type":"git","url":"git+https://github.com/postmanlabs/npm-cli-login.git"},"author":{"name":"Postman Team","email":"help@getpostman.com"},"license":"Apache-2.0","homepage":"https://github.com/postmanlabs/npm-cli-login#readme","dependencies":{"npm-registry-client":"7.0.9"},"gitHead":"432af8629b66f3fdf5e6bf75118fdcc5320df430","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"_id":"npm-cli-login@0.0.3","scripts":{},"_shasum":"b885b82c22f9aea53101f9b6ae23cc7ab0af9bac","_from":".","_npmVersion":"2.11.2","_nodeVersion":"4.1.1","_npmUser":{"name":"madebysid","email":"me@madebysid.com"},"dist":{"shasum":"b885b82c22f9aea53101f9b6ae23cc7ab0af9bac","size":1588,"noattachment":false,"key":"/npm-cli-login/-/npm-cli-login-0.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/npm-cli-login/download/npm-cli-login-0.0.3.tgz"},"maintainers":[{"name":"jviotti","email":"juanchiviotti@gmail.com"}],"_npmOperationalInternal":{"host":"packages-6-west.internal.npmjs.com","tmp":"tmp/npm-cli-login-0.0.3.tgz_1455619810696_0.22894700709730387"},"directories":{},"publish_time":1455619812602,"_hasShrinkwrap":false,"_cnpm_publish_time":1455619812602,"_cnpmcore_publish_time":"2021-12-16T11:51:36.955Z"}},"readme":"# npm-cli-login [![Build Status](https://travis-ci.org/postmanlabs/npm-cli-login.svg?branch=master)](https://travis-ci.org/postmanlabs/npm-cli-login)\n\nAllows you to log in to NPM without STDIN, STDOUT. Use in places like CI build systems.\nAlso creates/modifies entries in the ~/.npmrc file for authentication.\n\n### Installation\n\n    npm install -g npm-cli-login\n\nUse -g flag to use npm-cli-login via the CLI\n\n### Usage\n\n##### CLI\n\n`npm-cli-login` expects the following environment variables to be set before you can use it to authenticate:\n\n- `NPM_USER`: NPM username\n- `NPM_PASS`: NPM password\n- `NPM_EMAIL`: NPM email\n- `NPM_REGISTRY`: (optional) Private NPM registry to log in to (Default: https://registry.npmjs.org)\n- `NPM_SCOPE`: (optional) Private NPM scope\n- `NPM_RC_PATH`: (optional) Path to a custom .npmrc file you want to update (Default: `~/.npmrc`)\n\nOnce the required ones are set, you can just run the following to log in:\n\n    npm-cli-login\n\nYou can also export variables and run it all in one line:\n\n    NPM_USER=testUser NPM_PASS=testPass NPM_EMAIL=test@example.com npm-cli-login\n\nThere is also support for command line arguments:\n\n- `-u`: NPM Username\n- `-p`: NPM Password\n- `-e`: NPM Email\n- `-r`: NPM Registry\n- `-s`: NPM Scope\n- `--quotes`: Set to `false` by default. Specifies whether your auth token requires quotes. This might required when your auth token has special characters, like `=`, `?` etc.\n- `--config-path`: Set to `~/.npmrc` by default. Can be used to configure a custom .npmrc file to edit.\n\nFor example: ```npm-cli-login -u testUser -p testPass -e test@example.com```\n\nOr: ```npm-cli-login -u testUser -p testPass -e test@example.com -r https://private.npm.com -s @privateNPM --quotes --config-path=\"./custom/path/\"```\n\nDo note that at least one of the two ways must be configured, that is, you must either provide the required fields (username, password and email) using the environment variables or the command line arguments (or both)\n\n##### Programmatic API\n\nTo use the package programmatically, just require the module and pass in your NPM auth details as arguments:\n\n    var npmLogin = require('npm-cli-login');\n    npmLogin(username, password, email [, registry, scope, quotes, configPath]);\n\n##### Example\n\nLogging in to the NPM registry:\n\n```\nvar npmLogin = require('npm-cli-login'),\n    username = 'testUser',\n    password = 'testPass',\n    email = 'test@example.com'\n\nnpmLogin(username, password, email)\n```\n\nLogging in to private NPM registries:\n\n```\nvar npmLogin = require('npm-cli-login'),\n    username = 'testUser',\n    password = 'testPass',\n    email = 'test@example.com',\n    registry = 'https://npm.example.com',\n    scope = '@myScope',\n    quotes = false,\n    configPath: './custom/path/'\n\nnpmLogin(username, password, email, registry, scope, configPath)\n```\n","_attachments":{},"homepage":"https://github.com/postmanlabs/npm-cli-login#readme","bugs":{"url":"https://github.com/postmanlabs/npm-cli-login/issues"},"license":"Apache-2.0"}