Commit Graph

60 Commits

Author SHA1 Message Date
Juan Cruz Viotti
c1e6a28640 Refactor validation to a single place 2015-10-21 09:37:25 -04:00
Juan Cruz Viotti
8913fb515b Implement user/password login with 2FA support 2015-10-21 08:28:20 -04:00
Juan Cruz Viotti
f8470287c1 Separate general help per topic relevance
Only list primary commands by default, unless a `--verbose` option is
passed to list the additional ones.

Fixes: https://github.com/resin-io/resin-cli/issues/101
2015-10-02 08:50:32 -04:00
Juan Cruz Viotti
79afa79fd9 Use settings from the SDK during login
This enforces all clients to use the Resin Settings Client version that
the SDK provides, reducing incompatibilities caused by different modules
requiring different Resin Settings Client versions.
2015-09-08 09:06:03 +03:00
Juan Cruz Viotti
dc257b5cab Check token validity against the API when login
Consider the following case:

The SDK is configured to point to staging, but the user passes a token
from production, or viceversa. Since the token is valid in a sense that
is valid JWT and contains real data, the CLI will report as a success.

The user will then get Unauthorized errors when using the API.
2015-09-05 20:17:34 +03:00
mike
b0650530cc Resin CLI Events integration. Fix #103 2015-09-05 19:15:31 +03:00
Juan Cruz Viotti
70c060b124 Refactor auth actions to use promises 2015-08-17 08:22:48 -04:00
Juan Cruz Viotti
e9ec6c67b2 Validate that email address is valid during signup. Fix #111
For this we use a third party dependency from npm called `valid-email`
to avoid hardcoding and having to mantain a regular expression.
2015-08-13 15:22:22 -04:00
Juan Cruz Viotti
57319f26a6 Slim down unused functionality 2015-08-12 08:17:46 -04:00
mike
f31eb7c2b5 Add email address to the returned information, when using whoami(). Fix #73. 2015-08-03 21:24:22 +03:00
mike
e2125b8ce9 Fix #73 2015-07-29 21:15:29 +03:00
mike
5b5d1be52f Integrate resin-cli-form 2015-07-27 19:50:47 +03:00
mike
64d83dccfb Add promise support for Resin-SDK dependency 2015-07-24 00:24:17 +03:00
Juan Cruz Viotti
8fa906dd48 Upgrade Resin CLI Visuals and use it's new capabilities 2015-06-11 12:46:56 -04:00
Juan Cruz Viotti
e9efb78280 Merge pull request #56 from resin-io/feature/login-feedback
Display feedback message after login
2015-06-03 08:46:18 -04:00
Juan Cruz Viotti
1ed9ae7d60 Open dashboardUrl instead of remoteUrl in auth login 2015-06-02 13:21:59 -04:00
Juan Cruz Viotti
34736c4e9b Display feedback message after login 2015-06-02 11:57:52 -04:00
Juan Cruz Viotti
f3e193be0f Make login command behave non interactively if a token is passed as an argument 2015-05-11 09:42:25 -03:00
Juan Cruz Viotti
8041905144 Remove duplicated whoami command 2015-04-20 12:46:43 -04:00
Juan Cruz Viotti
a96ab487ba Fix bug with login with token
The commit was merged from an older branch, in which settings was
still part of the SDK.
2015-04-08 08:25:27 -04:00
Juan Cruz Viotti
03f05305cf Fix tiny text issue 2015-04-07 08:07:06 -04:00
Juan Cruz Viotti
064afd6705 Fetch TOKEN_URL from the resin sdk 2015-04-06 17:05:13 -04:00
Juan Cruz Viotti
978ff91f87 Remove tab query from preferences token url constant
Tab queries were removed from the web frontend.
2015-04-06 17:04:43 -04:00
Juan Cruz Viotti
1cd0f02db5 Attempt to open a browser to the token location automatically 2015-04-06 17:04:03 -04:00
Juan Cruz Viotti
77695bb505 Allow login with token 2015-04-06 17:02:53 -04:00
Juan Cruz Viotti
cd8bb7882e Reimplement whoami command 2015-03-19 15:57:43 -04:00
Juan Cruz Viotti
6a83a537c7 Implement basic documentation generation mechanism 2015-03-03 11:32:24 -04:00
Juan Cruz Viotti
7dd34f4a0e Fix option parameter name issue 2015-02-12 10:20:00 -04:00
Juan Cruz Viotti
8275275a05 Make login command accept options instead of colon separated credentials
For consistency
2015-02-09 11:48:13 -04:00
Juan Cruz Viotti
4d49655ab2 Enable registering programatically 2015-02-09 11:43:10 -04:00
Juan Cruz Viotti
50325d0f8f Make use of resin-cli-visuals and get rid of local ui module 2015-01-21 09:50:19 -04:00
Juan Cruz Viotti
d49677581b Make use of Capitano permissions feature 2015-01-16 09:34:59 -03:00
Juan Cruz Viotti
5abc4e550f Move command declarations next to their definitions 2015-01-15 14:18:39 -03:00
Juan Cruz Viotti
a6282d2b28 Get rid of log module
Didn't provide that much value
2015-01-15 11:36:43 -03:00
Juan Cruz Viotti
3e055b32d2 Update Capitano to v1.2.0 and make use of done callback feature 2015-01-15 10:47:17 -03:00
Juan Cruz Viotti
f36e13658f Remove credentials filtering when logging in after registering 2015-01-09 13:06:17 -03:00
Juan Cruz Viotti
05812ba442 Implement and make use of errors.handleCallback()
This function is introduced to remove some duplication
2015-01-09 12:22:18 -03:00
Juan Cruz Viotti
8c02e88ab5 Add logout error handler 2015-01-09 10:38:06 -03:00
Juan Cruz Viotti
12f46be691 Partially get rid of nested sdk 2015-01-08 09:39:38 -03:00
Juan Cruz Viotti
16ddd8ccb6 Implement interactive signup form 2014-12-24 11:14:30 -04:00
Juan Cruz Viotti
8d08affcd8 Move parseCredentials() to helpers 2014-12-22 15:48:11 -04:00
Juan Cruz Viotti
46ebb7b1fd Move errors.handle() out of resin sdk 2014-12-22 12:47:12 -04:00
Juan Cruz Viotti
2351fa25a0 Move log out of resin sdk 2014-12-22 12:41:14 -04:00
Juan Cruz Viotti
6cfe2bdc49 Make use of Capitano for command line parsing 2014-12-19 09:15:38 -04:00
Juan Cruz Viotti
b30b41d4bb Enable auth whoami command 2014-12-12 10:25:32 -04:00
Juan Cruz Viotti
4b74ec7fc4 Move UI outside resin module 2014-12-05 12:00:15 -04:00
Juan Cruz Viotti
0c55a4afb6 Integrate CliConf with application 2014-12-05 11:09:31 -04:00
Juan Cruz Viotti
511e753256 Support user defined configuration file 2014-12-03 12:03:54 -04:00
Juan Cruz Viotti
e21c1588c9 Remove config urls abs url map 2014-12-01 10:13:35 -04:00
Juan Cruz Viotti
5e3d973725 Implement command permissions 2014-11-27 10:06:11 -04:00