From 11354de5967aaa4f98f7318e51aa3dfd21413b31 Mon Sep 17 00:00:00 2001 From: Juan Cruz Viotti Date: Tue, 12 Jan 2016 10:30:56 -0400 Subject: [PATCH] Print an informative message after successful login --- build/actions/auth.js | 3 ++- lib/actions/auth.coffee | 20 +++++++++++++++++++- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/build/actions/auth.js b/build/actions/auth.js index 96451848..88719055 100644 --- a/build/actions/auth.js +++ b/build/actions/auth.js @@ -86,8 +86,9 @@ limitations under the License. console.log("\nLogging in to " + resinUrl); return login(options); }).then(resin.auth.whoami).tap(function(username) { + events.send('user.login'); console.info("Successfully logged in as: " + username); - return events.send('user.login'); + return console.info('\nNow what?\n\nRun the following command to get a device started with Resin.io\n\n $ resin quickstart\n\nFind out about more super powers by running:\n\n $ resin help\n\nIf you need help, or just want to say hi, don\'t hesitate in reaching out at:\n\n GitHub: https://github.com/resin-io/resin-cli/issues/new\n Gitter: https://gitter.im/resin-io/chat'); }).nodeify(done); } }; diff --git a/lib/actions/auth.coffee b/lib/actions/auth.coffee index 5e5ef0e0..cc0a5e34 100644 --- a/lib/actions/auth.coffee +++ b/lib/actions/auth.coffee @@ -112,8 +112,26 @@ exports.login = return login(options) .then(resin.auth.whoami) .tap (username) -> - console.info("Successfully logged in as: #{username}") events.send('user.login') + + console.info("Successfully logged in as: #{username}") + console.info ''' + + Now what? + + Run the following command to get a device started with Resin.io + + $ resin quickstart + + Find out about more super powers by running: + + $ resin help + + If you need help, or just want to say hi, don't hesitate in reaching out at: + + GitHub: https://github.com/resin-io/resin-cli/issues/new + Gitter: https://gitter.im/resin-io/chat + ''' .nodeify(done) exports.logout =