guardian / ssm-scala

ssh replacement: CLI program that wraps SSM's EC2 Run Command
Apache License 2.0
21 stars 0 forks source link

ZSH/bash completion #88

Open rahilb opened 6 years ago

rahilb commented 6 years ago

ISSUE

There is no tab completion, and flags are difficult to remember.

Steps to Reproduce

ssm [TAB]

(no completion)

Actual Results (include screenshots)

Expected Results (include screenshots)

A nicely formatted list of things I can do with the command, e.g. git commit --[TAB] gives something like

 rahil_bohra@32597> git commit --[TAB]
--all                           -- stage all modified and deleted paths
--allow-empty                   -- allow recording an empty commit
--allow-empty-message           -- allow recording a commit with an empty message
--amend                         -- amend the tip of the current branch
...
shtukas commented 6 years ago

Thats's an excellent idea @rahilb

shtukas commented 6 years ago

@rahilb I have just noticed that I don't have tab completion for git (when using either bash or zsh). Are you using any particular config ?

rahilb commented 6 years ago

Yep, i'm using oh-my-zsh (which is brilliant btw), it ships with various completions built in. To enable git completion after installing add the line plugins=(git) to ~/.zshrc.

shtukas commented 6 years ago

Oh, that makes sense. I am happy to do it but we would have to pair on it. Could you drop something in my calendar ? Anytime will do :)