Skip to content

Commit

Permalink
Fix/improve zsh completion
Browse files Browse the repository at this point in the history
Fixes garbage output in completion with certain completion settings and
when there are no projects available.
  • Loading branch information
ZeroKnight committed Jun 20, 2018
1 parent 43ab354 commit 573fcad
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Expand Up @@ -2,6 +2,7 @@
- Remove confusing README section about the pane-base-index and
window-base-index options. These options can be set independently of one
another now that #542 and #543 are merged.
- Fix zsh completion when there are no projects

## 0.11.3
### Misc
Expand Down
5 changes: 3 additions & 2 deletions completion/tmuxinator.zsh
Expand Up @@ -4,8 +4,9 @@ _tmuxinator() {
projects=(${(f)"$(tmuxinator completions start)"})

if (( CURRENT == 2 )); then
_describe -t commands "tmuxinator subcommands" commands
_describe -t projects "tmuxinator projects" projects
_alternative \
'commands:: _describe -t commands "tmuxinator subcommands" commands' \
'projects:: _describe -t projects "tmuxinator projects" projects'
elif (( CURRENT == 3)); then
case $words[2] in
copy|debug|delete|open|start)
Expand Down

0 comments on commit 573fcad

Please sign in to comment.