Closed bartekpacia closed 2 months ago
Here's what I ended up with...
Installed via homebrew on my work laptop. These installs always drop completions in the same directory:
% brew install tart
==> Fetching cirruslabs/cli/tart
==> Downloading https://github.com/cirruslabs/tart/releases/download/2.10.0/tart-arm64.tar.gz
Already downloaded: /Users/thomas/Library/Caches/Homebrew/downloads/5407e492e27b73c6de2bc751f5233f1d57ff9e4c2c96677e843398931b7b1a47--tart-arm64.tar.gz
==> Reinstalling cirruslabs/cli/tart
==> Caveats
See the GitHub repository for more information
zsh completions have been installed to:
/opt/homebrew/share/zsh/site-functions <-- completions are here
==> Summary
🍺 /opt/homebrew/Cellar/tart/2.10.0: 12 files, 11.6MB, built in 2 seconds
==> Running `brew cleanup tart`...
Disable this behaviour by setting HOMEBREW_NO_INSTALL_CLEANUP.
Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).
I use OMZSH; given the location of the completions, omzsh should just pick it up and run with it.
That said, my work laptop totally fires off completions - just realized my personal laptop does not 😂 that alone implies an environmental (configuration) issue.
I'll test some more and post if anything reveals itself.
I found a quick fix that allows me to get past this but:
% cat ~/.zprofile
# Homebrew Stuff
eval "$(/opt/homebrew/bin/brew shellenv)"
FPATH="$(brew --prefix)/share/zsh/site-functions:${FPATH}"
The first line is necessary; the second like only exists because of a failure somewhere upstream. The failure should be identified and solved.
But this works in a pinch.
Assumptions:
tart list
output:Current behavior
When completion is triggered, nothing is printed.
Expected behavior
Available VMs (the
local
ones) are suggested:Implementation
Tart's CLI uses Swift ArgumentParser, and looks like it has support for accurate, customized shell completions and supports the use case I described above.
I'm happy to submit a PR for this when I find some free time, if you agree with this feature suggestion.