Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to recreate local password key chain #186

Open
unional opened this issue Feb 6, 2018 · 3 comments
Open

Add option to recreate local password key chain #186

unional opened this issue Feb 6, 2018 · 3 comments
Labels

Comments

@unional
Copy link

unional commented Feb 6, 2018

My token used by sem-ver for npm seems to be messed up and I want to recreate a new one.

Right now I have to do --ask-for-passwords every time.

It would be nice to have --clear-npm-token or --reset-tokens option.

@pvdlg pvdlg added the cli label Feb 6, 2018
@gr2m
Copy link
Member

gr2m commented Feb 6, 2018

what happens if you run it without the --ask-for-passwords flags? I think it should re-create tokens, too? I’m pretty sure I did that in the past to reset a repository

@unional unional changed the title Add option to recreate token Add option to recreate local password key chain Mar 31, 2018
@unional
Copy link
Author

unional commented Mar 31, 2018

Sorry, my original question was not clear because I didn't have a correct understanding of how it works.

What I am looking for is a way to reset the password token saved in the local computer (is it saved in key-chain?).

Right now every time when I try to setup a new repo without --ask-for-passwords, I get this:

> semantic-release-cli setup
? What is your npm registry? https://registry.npmjs.org/
? What is your npm username? unional
ERR! semantic-release Error: Could not login to npm.
ERR! semantic-release     at getNpmToken (/Users/hwong/.nvm/versions/node/v9.4.0/lib/node_modules/semantic-release-cli/src/lib/npm.js:51:21)
ERR! semantic-release     at <anonymous>
ERR! semantic-release     at process._tickCallback (internal/process/next_tick.js:160:7)
ERR! semantic-release  { Error: Could not login to npm.
ERR! semantic-release     at getNpmToken (/Users/hwong/.nvm/versions/node/v9.4.0/lib/node_modules/semantic-release-cli/src/lib/npm.js:51:21)
ERR! semantic-release     at <anonymous>
ERR! semantic-release     at process._tickCallback (internal/process/next_tick.js:160:7)
ERR! semantic-release   stack: 'Error: Could not login to npm.\n    at getNpmToken (/Users/hwong/.nvm/versions/node/v9.4.0/lib/node_modules/semantic-release-cli/src/lib/npm.js:51:21)\n    at <anonymous>\n    at process._tickCallback (internal/process/next_tick.js:160:7)' }

If I use --ask-for-passwords it will work but does not update the token saved locally.

@gr2m
Copy link
Member

gr2m commented Mar 31, 2018

is it saved in key-chain?

Yes, I think it would be best to delete it from there directly if you want to reset them

Error: Could not login to npm

That looks like an issue on npm, see #190

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants