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

cli: [FIX] Fix target add command (not store targets at config file) #38

Merged
merged 3 commits into from
Mar 30, 2019

Conversation

mdjunior
Copy link
Contributor

@mdjunior mdjunior commented Mar 29, 2019

This PR fixes an incorrect behavior at target-add command.

Running target-add command before, new target is not add to config file:

$ gsh target-add example https://gsh-api.example.org -s
Using config file: /Users/manoel.junior/.gsh/config.yaml

$ cat /Users/manoel.junior/.gsh/config.yaml
{}

This error happen because viper.Set() is not invoked to save targets at config file. Is a simple commit (1 line) 1202cd4.

Other points is that target-* commands don't have a result message to user. Example:

$ gsh target-add example https://gsh-api.example.org -s
Using config file: /Users/manoel.junior/.gsh/config.yaml

This PR addresses it, adding messages explaining to user what is happen after running command with success state (wiki page updated).

Finally, this PR changes name of GSH CLI from gshc to gsh at code and wiki. Homebrew and snap installs GSH CLI as gsh command and at this way is more clear to user this name.

@rafaveira3
Copy link
Contributor

Good catch, @mdjunior ! Sounds good to me.

@rafaveira3 rafaveira3 merged commit e332da3 into master Mar 30, 2019
@rafaveira3 rafaveira3 deleted the fix-target-add branch March 30, 2019 00:21
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.

2 participants