-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Unregister and login commands #1201
Conversation
oaaa, will test asap. |
Super exciting. Nice one, Mat! |
process.nextTick(function () { | ||
// Verify name | ||
if (!name) { | ||
return logger.emit('error', createError('Please type a name', 'EINVNAME')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess it's not necessary to introduce new error type. Command will show help if name is empty, so the only way this code can be run is something like bower register ' '
. You don't need to verify name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1
Otherwise OK :) EDIT: Nevermind 401/403. It's different kind of issue |
return Q.ninvoke(github.authorization, 'create', { | ||
scopes: ['user', 'repo'], | ||
note: 'Bower command line client (' + (new Date()).toISOString() + ')' | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eventually .fail() that extracts github's json error message here.
For now if login fails I get:
bower 401 {"message":"Bad credentials","documentation_url":"https://developer.github.com/v3"}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1
Maybe we should disable removing package if other packages are depending on it? I guess it would require fetching dependency information for each package, so it's not ASAP. |
} | ||
|
||
var questions = [ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this new line
@wibblymat you need to add these new entries to the general bower help json file in the templates. |
What's the latest on this? |
Nice. I can't wait for this to get released. |
+1 this is awesome - what's blocking merging this? |
Rebased in #1719 |
@satazor @svnlto @sindresorhus
Please test this thoroughly, and check that everything makes sense. Probably best to only unregister things that you registered for testing!
The UX may not be right, comments welcome.