mirror of
https://github.com/balena-io/balena-cli.git
synced 2024-12-23 15:32:22 +00:00
Add information on how to login on user permission error
This commit is contained in:
parent
de0649c980
commit
a346c3f043
@ -37,7 +37,7 @@ limitations under the License.
|
||||
capitano.permission('user', function(done) {
|
||||
return resin.auth.isLoggedIn().then(function(isLoggedIn) {
|
||||
if (!isLoggedIn) {
|
||||
throw new Error('You have to log in');
|
||||
throw new Error('You have to log in to continue\n\nRun the following command to go through the login wizard:\n\n $ resin login');
|
||||
}
|
||||
}).nodeify(done);
|
||||
});
|
||||
|
@ -26,7 +26,13 @@ update = require('./utils/update')
|
||||
capitano.permission 'user', (done) ->
|
||||
resin.auth.isLoggedIn().then (isLoggedIn) ->
|
||||
if not isLoggedIn
|
||||
throw new Error ('You have to log in')
|
||||
throw new Error '''
|
||||
You have to log in to continue
|
||||
|
||||
Run the following command to go through the login wizard:
|
||||
|
||||
$ resin login
|
||||
'''
|
||||
.nodeify(done)
|
||||
|
||||
capitano.command
|
||||
|
Loading…
Reference in New Issue
Block a user