ankitpokhrel / jira-cli

🔥 Feature-rich interactive Jira command line.
MIT License
3.73k stars 178 forks source link

Shell completions zsh not completing #686

Closed nanvenomous closed 6 months ago

nanvenomous commented 7 months ago

Describe the bug I followed the instructions in jira completion --help for zsh, but on <tab> I get the default directory completion

Please provide following details

  1. JiraCLI Version:
    (Version="v1.4.0", GitCommit="", CommitDate="", GoVersion="go1.21.4", Compiler="gc", Platform="linux/amd64")
  2. Are you using Jira cloud or on-premise jira server? Not yet set up (N/A)
  3. What operating system are you using? Also mention version.
    Arch Linux x86_64,  Kernel: 6.6.1-arch1-1
  4. What terminal are you using? Also mention version.
     git@github.com:siduck/st.git commit: 5c4df963070573db7cee2eafb320d84e477c3507

To Reproduce

Steps to reproduce the behavior:

  1. add autoload -U compinit; compinit to ~/.zshrc
  2. jira completion zsh > _jira
    mv ./_jira $fpath[1]
  3. Start a new shell
  4. run
    jira <tab>

Expected behavior

Actual behavior

Additional context

nanvenomous commented 7 months ago

Once I authenticated and ran jira init now the completions work.

nanvenomous commented 7 months ago

Once I authenticated and ran jira init now the completions work.

ankitpokhrel commented 6 months ago

Hi @nanvenomous, since the completion config is auto generated via spf13/cobra lib, let's keep the behavior as is for now. Completions seem to work fine after configuring the tool.