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

Simplify CLI #60

Closed
jamesroutley opened this issue Feb 27, 2017 · 2 comments
Closed

Simplify CLI #60

jamesroutley opened this issue Feb 27, 2017 · 2 comments

Comments

@jamesroutley
Copy link
Contributor

Full change list:

Current:                  Proposed:
continue-update-rollback  [unchanged]
create-change-set         [unchanged]
create-stack              create
delete-change-set         [unchanged]
delete-env                delete -r
delete-stack              delete
describe-change-set       [unchanged]
describe-env              [unchanged] (maybe it would be working adding a describe-stack command for symmetry)
describe-env-resources    describe-resources -r
describe-stack-outputs    describe-outputs
describe-stack-resources  describe-resources
execute-change-set        [unchanged]
generate-template         [unchanged]
get-stack-policy          get-policy
launch-env                launch -r
launch-stack              launch
list-change-sets          [unchanged]
lock-stack                lock
set-stack-policy          set-policy
unlock-stack              unlock
update-stack              update
update-stack-cs           update-cs (maybe implement this as a flag: update -cs)
validate-template         [unchanged]

Implementation

Rename CLI commands.

Pros

  • The -r/--recursive syntax is more in keeping with Unix standards (e.g. cp, mv, grep)
  • Commands are less verbose

Cons

  • The original reason for having separate commands for building stacks and environments was to avoid users accidentally deleting whole environments. This would be mitigated by proposal 01.
@jamesroutley jamesroutley modified the milestone: v2 Feb 27, 2017
This was referenced Mar 1, 2017
@theseanything
Copy link
Contributor

theseanything commented Mar 7, 2017

Just brainstorming ideas - this is a possible "aws cli"-esk structure of sceptre

Proposed:                 Current:
stack create              create-stack
stack update              update-stack
stack update -c           update-stack-cs
stack delete              delete-stack
stack delete -r           delete-env
stack launch              launch-stack
stack launch -r           launch-env
stack status              describe-stack
stack status -r           describe-env
stack rollback            continue-update-rollback
stack describe-outputs    describe-stack-outputs
stack describe-resources  describe-stack-resouces
change-set create         create-change-set
change-set delete         delete-change-set
change-set execute        execute-change-set
change-set list           list-change-sets
template validate         validate-template
template generate         generate-template
policy lock               lock-stack
policy unlock             unlock-stack
policy get                get-stack-policy
policy set                set-stack-policy

Although I like just having the command at the start like suggest in the initial comment. However not as neat due to the sets of change-set and template commands and continue-rollback.

I'm less bothered with keeping to strict unix standards as modern cli's have moved on from that (e.g. k8, docker, npm etc) and not sure what we benefit from it.

How about status instead of describe-env or possibly describe-stack?

@jamesroutley
Copy link
Contributor Author

Oh yeah, that's cool - I like the way things are organised. Issues:

  • Stack is an AWS word isn't it? - if we also support Azure would it be better to avoid that word?
  • We remove the word "stack" from some of the commands even though those commands still fundamentally deal with stacks. The one of the arguments provided to those commands would still need to be a stack name.

theseanything added a commit that referenced this issue Oct 31, 2017
theseanything added a commit that referenced this issue Oct 31, 2017
theseanything added a commit that referenced this issue Oct 31, 2017
theseanything added a commit that referenced this issue Oct 31, 2017
theseanything added a commit that referenced this issue Oct 31, 2017
@theseanything theseanything self-assigned this Nov 9, 2017
theseanything added a commit that referenced this issue Nov 15, 2017
theseanything added a commit that referenced this issue Dec 5, 2017
theseanything added a commit that referenced this issue Dec 5, 2017
theseanything added a commit that referenced this issue Dec 13, 2017
larsbutler pushed a commit to larsbutler/sceptre that referenced this issue Mar 5, 2018
* [Resolves Sceptre#60] Refactor CLI

* Add docstrings and print help on subcammands
kifbv pushed a commit to kifbv/sceptre that referenced this issue Mar 11, 2018
* [Resolves Sceptre#60] Refactor CLI

* Add docstrings and print help on subcammands
kifbv pushed a commit to kifbv/sceptre that referenced this issue Mar 11, 2018
…completion

* 'bash-completion' of github.com:kifbv/sceptre:
  add support for options (--var-file, etc)
  remove foreign commands
  add bash completion script
  [Resolves Sceptre#60] Refactor CLI (Sceptre#278)
  [Resolve Sceptre#272] Enable intergration tests in generic AWS accounts (Sceptre#281)
  Fix nested stack dependency resolution and on_failure param (Sceptre#276)
  [Resolves Sceptre#5] Refactor Config class to ConfigReader class
  [Resolve Sceptre#11] Refactor validate template (Sceptre#209)
  Entry point hooks (Sceptre#205)
  Remove bash and asg scheduled actions hooks
  Remove bash and asg scheduled actions hooks
  Fix unit tests
  Remove project variables
  Hotfix for circle pypi tag deployment
JuanCanham pushed a commit to JuanCanham/sceptre that referenced this issue Jun 14, 2018
* [Resolves Sceptre#60] Refactor CLI

* Add docstrings and print help on subcammands
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants