-
Notifications
You must be signed in to change notification settings - Fork 831
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
$HOME/.asdf/completions/asdf.bash:68: command not found: complete #692
Comments
Interesting. |
@jthegedus a couple of Zsh plugins also do this same sourcing of the completion: https://github.com/kiurchv/asdf.plugin.zsh/blob/master/asdf.plugin.zsh#L5 |
Ah, yes, a number of the asdf plugins will source this as the ZSH completions are new and those plugins have not been updated. I have opened a discussion around how to correctly implement the new completions with the As with the |
🎺 🎺 🎺 I would advise anyone looking to help to read ohmyzsh/ohmyzsh#8779 as the Thanks for your patience while we work towards a better ZSH experience for all |
Chiming in with my experience in case it helps someone track this down: Works for measdf version: v0.7.6-6207e42 My current dotfiles - see
Note: I am not sure that these settings are remotely correct, but they are working. Upgrade steps
If I source the previous Here's a branch of my dotfiles with the new configuration. I also tried installing If I Notes:
EnvironmentOS: MacOS Mojave 10.14.6 zsh version: zsh 5.7.1 (x86_64-apple-darwin17.7.0) zsh-related homebrew libraries
zplug plugins
Note that I am not using a zsh manager like |
One more angle: I just tried deleting |
@shipstar Thanks for reporting. I would recommend only testing with As with your specific error of
I would also suggest looking for and deleting any |
Thanks for the update on I did have a Assuming I do have some latent bash config values hanging around, any ideas why zsh autocompletion is working for other tools but not asdf? Seems odd that nothing else would be throwing the same error. I'll keep digging and report back if I figure it out! EDIT: I know dotfiles can be a tangled mess, so not expecting specific help with my situation. Just trying to understand the variables in play here, e.g. |
Possible progress - when I run
If I change that line in I'm not sure what's placing the incorrect entry into I'll edit my |
I am also seeing this error. In my dotfile, I have
, and on terminal startup, I am seeing
My ZSH config is quite close to a vanilla grml-zsh-config, so not too much weird stuff going on. I'd also like to use this chance to say thank you for a great, simple version manager! When I was able to replace nvm + similar things for other languages with asdf, my shell startup went from annoying to instant. Thanks! |
Reverting to
in the asdf install folder, I am no longer seeing any errors on startup. |
@shipstar That is an interesting find, thanks. Perhaps the way the Brew installation is setting the completions is incorrect. I will test on a macOS machine. @teodorlu a few questions:
I think the main issue here is the changes to the
The docs are very confusing atm for ZSH users (to much information on screen) and the migration path from Your reports are appreciated. Keep the info coming. |
Nope, I'm on Linux. Ubuntu 18.04. I think I cloned directly into
I did not add the completions script back into the mix. I can try re-adding them and see what happens.
Attached: zcompdump.txt. Crossing my fingers that no private stuff has snuck in there ... |
@teodorlu Thanks for the further information. It seems from your # source asdf
. $HOME/.asdf/asdf.sh
# add asdf completions to fpath
fpath=(${ASDF_DIR}/completions $fpath)
# run compinit
autoload -Uz compinit && compinit version |
New docs are out which should make it easier to see the config required for your specific OS/Shell/Install Method combination. |
So @Quintasan @goetzc @shipstar @teodorlu was the information in this thread enough for you to each resolve your problems? |
@jthegedus since I'm a lazy bum I'm going to wait for ohmyzsh/ohmyzsh#8837 to be merged and report back if it fixes the problem ;) EDIT: I couldn't wait after all - it works! |
I still have the same issue in my
The completions in I'm planning to move to a new computer in the next few weeks, so I'll test from a fresh install and try to report back then. Despite my minor issues, I just wanted to say that the new docs are much easier to follow. 💯Thanks for making time to improve those! |
I will see if I can replicate on my macOS device, thanks @shipstar |
@shipstar I was unable to reproduce your issue of
on a fresh install of macOS. Let me know if the state of your env changes. There's perhaps more variables of your env we need to dig into to solve this. Given the OP has had their issue resolved and the docs have been updated to prevent their particular case, I am going to close this issue. @shipstar please don't hesitate to open a new issue and assign it to me if your problem persists. We can continue debugging your setup there 👍 |
Adding this fixed it for me: |
@cocoonkid It sounds like you're using the Bash completions. If your Shell is ZSH we have native ZSH completions which the documentation site will help you setup 😄 https://asdf-vm.com/#/core-manage-asdf-vm |
I have had luck putting this in my # Turn on ZSH autocomplete
# https://unix.stackexchange.com/a/477909
autoload -Uz compinit && compinit
# Setup Homebrew in PATH =>
eval "$(/opt/homebrew/bin/brew shellenv)"
# Setup asdf
# https://hackercodex.com/guide/python-development-environment-on-mac-osx/
. $(brew --prefix asdf)/asdf.sh
asdf reshim python
asdf reshim nodejs
# https://github.com/asdf-vm/asdf/issues/692#issuecomment-642748733
autoload -U +X bashcompinit && bashcompinit
# set up bash completions
# https://blog.natterstefan.me/how-to-use-multiple-node-version-with-asdf
. $(brew --prefix asdf)/etc/bash_completion.d/asdf.bash For some reason I don't understand the |
Steps to reproduce
Expected behavior
No errors happen
Actual behavior
I'm getting:
on every terminal launch
Environment
OS: Ubuntu 18.04
asdf version: v0.7.8-4a3e3d6
zsh version: zsh 5.4.2 (x86_64-ubuntu-linux-gnu)
The text was updated successfully, but these errors were encountered: