diff options
author | Tristan Sloughter <tristan.sloughter@gmail.com> | 2015-09-07 13:19:11 -0500 |
---|---|---|
committer | Tristan Sloughter <tristan.sloughter@gmail.com> | 2015-09-07 13:19:11 -0500 |
commit | d7f2226d31f4708518c1ddb41f7666f9c1d0f151 (patch) | |
tree | 1ef34c11592cac77eac4ccfbd047bcb952642bef /priv | |
parent | 77e5e6b8f3028626afb4a687c1b02709a2dbd9b6 (diff) | |
parent | 04da2ffd5e65895ff0beb6f8f3ffd0deb95328de (diff) |
Merge pull request #761 from talentdeficit/rebar_path
`rebar3 path' provider
Diffstat (limited to 'priv')
-rw-r--r-- | priv/shell-completion/bash/rebar3 | 12 | ||||
-rw-r--r-- | priv/shell-completion/fish/rebar3.fish | 12 | ||||
-rw-r--r-- | priv/shell-completion/zsh/_rebar3 | 11 |
3 files changed, 35 insertions, 0 deletions
diff --git a/priv/shell-completion/bash/rebar3 b/priv/shell-completion/bash/rebar3 index 40009b7..511d537 100644 --- a/priv/shell-completion/bash/rebar3 +++ b/priv/shell-completion/bash/rebar3 @@ -23,6 +23,7 @@ _rebar3() eunit \ help \ new \ + path \ pkgs \ plugins \ release \ @@ -98,6 +99,17 @@ _rebar3() elif [[ ${prev} == new ]] ; then sopts="-f" lopts="--force" + elif [[ ${prev} == path ]] ; then + sopts="-s" + lopts="--app \ + --base \ + --bin \ + --ebin \ + --lib \ + --priv \ + --separator \ + --src \ + --rel" elif [[ ${prev} == pkgs ]] ; then : elif [[ ${prev} == plugins ]] ; then diff --git a/priv/shell-completion/fish/rebar3.fish b/priv/shell-completion/fish/rebar3.fish index df1697e..f3b449e 100644 --- a/priv/shell-completion/fish/rebar3.fish +++ b/priv/shell-completion/fish/rebar3.fish @@ -44,6 +44,7 @@ end ## eunit Run EUnit Tests. ## help Display a list of tasks or help for a given task or subtask. ## new Create new project from templates. +## path Print paths to build dirs in current profile. ## pkgs List available packages. ## release Build release of project. ## relup Create relup of releases. @@ -118,6 +119,17 @@ complete -f -c 'rebar3' -n '__fish_rebar3_needs_command' -a new -d "Create new p complete -f -c 'rebar3' -n '__fish_rebar3_using_command new' -s f -l force -d "Overwrite existing files" complete -f -c 'rebar3' -n '__fish_rebar3_using_command new' -a help -d "Display all variables and arguments for each template" +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command' -a paths -d "Print paths to build dirs in current profile." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l app -d "Comma seperated list of applications to return paths for." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l base -d "Return the `base' path of the current profile." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l bin -d Return the `bin' path of the current profile." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l ebin -d "Return all `ebin' paths of the current profile's applications." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l lib -d "Return the `lib' path of the current profile." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l priv -d "Return the `priv' path of the current profile's applications." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -s s -l separator -d "In case of multiple return paths, the separator character to use to join them." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l src -d "Return the `src' path of the current profile's applications." +complete -f -c 'rebar3' -n '__fish_rebar3_needs_command paths' -l rel -d "Return the `rel' path of the current profile." + complete -f -c 'rebar3' -n '__fish_rebar3_needs_command' -a pkgs -d "List available packages." complete -f -c 'rebar3' -n '__fish_rebar3_needs_command' -a release -d "Build release of project." complete -f -c 'rebar3' -n '__fish_rebar3_needs_command' -a relup -d "Create relup of releases." diff --git a/priv/shell-completion/zsh/_rebar3 b/priv/shell-completion/zsh/_rebar3 index 04575bc..8855bdf 100644 --- a/priv/shell-completion/zsh/_rebar3 +++ b/priv/shell-completion/zsh/_rebar3 @@ -108,6 +108,17 @@ _rebar3 () { '(-f --force)'{-f,--force}'[ overwrite existing files]' \ && ret=0 ;; + (path) + _arguments \ + '(--app)--app[Comma seperated list of applications to return paths for.]:apps' \ + '(--base)--base[Return the `base' path of the current profile.]' \ + '(--bin)--bin[Return the `bin' path of the current profile.]' \ + '(--ebin)--ebin[Return all `ebin' paths of the current profile's applications.]' \ + '(--lib)--lib[Return the `lib' path of the current profile.]' \ + '(--priv)--priv[Return the `priv' path of the current profile's applications.]' \ + '(-s --separator)--separator[In case of multiple return paths, the separator character to use to join them.]' \ + && ret=0 + ;; (pkgs) _message 'List available packages.' && ret=0 ;; |