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

config: add a dedicated account creation command #202

Merged

Conversation

falzm
Copy link
Contributor

@falzm falzm commented Nov 22, 2019

This change introduces an explicit exo config add command allowing
users to create a CLI configuration accounts. Includes some light
internal refactoring to make code more readable.

$ ./exo config add blah
[+] API Key [none]: EXOxxxxxxxxxxxxxxxxxxxxxxx
[+] Secret Key [none]: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Retrieving account information... done!

[+] Name [xxxxxx@exoscale.com]: blah
✔ ch-gva-2
You chose "ch-gva-2"
[+] Set [blah] as default account? [yN]: y

$ ./exo config
To configure a new account, run `exo config add`
Use the arrow keys to navigate: ↓ ↑ → ←
? Configured accounts (* = default account):
  ▸ alice
    bob
    carl
    blah*

This change introduces an explicit `exo config add` command allowing
users to create a CLI configuration accounts. Includes some light
internal refactoring to make code more readable.
Copy link
Contributor

@illi-j illi-j left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the exo config set command really useful?
because we can already change the default account with the command exo config

@falzm
Copy link
Contributor Author

falzm commented Nov 25, 2019

Is the exo config set command really useful?
because we can already change the default account with the command exo config

@illi-j one usage I can think of is in non-interactive situations (e.g. scripts), but I agree it's not extremely useful and could be removed in an upcoming major version of the CLI.

Copy link
Contributor

@illi-j illi-j left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thx @falzm !
LGTM 👍

Copy link
Member

@pierre-emmanuelJ pierre-emmanuelJ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🤙

@falzm falzm merged commit 8a169bb into master Nov 26, 2019
@falzm falzm deleted the marc/ch7339/cli-missing-explicit-configuration-profile branch November 26, 2019 09:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants