I was setting up my development environment on Ubuntu 20.04 following a video on Youtube and after running the command

$ echo -e '\n. $HOME/.asdf/completions/asdf.bash' >> ~/.zshrc

Every time I open the terminal the message appears:

/home/gustavo/.asdf/completions/asdf.bash:80: command not found: complete

Does anyone know what I could have done wrong and how can I fix it?

Just to point out, I'm a beginner.

  • 1
    Look at asdf.bash and remove the offending statement. Otherwise edit .zshrc and remove the script so it no longer starts. Commented Apr 3, 2022 at 22:50
  • 1
    Post the relevant section of asdf.bash that contains ~/.zshrc you should provide 5-10 lines at most.
    – Ramhound
    Commented Apr 4, 2022 at 0:13
  • What research have you done and what have you tried? Commented Apr 4, 2022 at 1:14

3 Answers 3


If you are mac user using .zsh

just add the following to your .zshrc file

autoload -U +X bashcompinit && bashcompinit
autoload -U +X compinit && compinit

for more info refer to link : https://github.com/eddiezane/lunchy/issues/57

duplicate answer : https://stackoverflow.com/a/73575734/1283215

  • thank you, this is a life saver!! Commented Jan 9 at 1:03

What that error means is that a command that you used in asdaf.bash is apparently no longer on your computer. To try and remedy the situation:

  • Is complete actually installed? Try using apt show complete to see if it's installed. If it is, [installed] should be at the end of the line.

  • Is complete another script? If so, use this syntax (assuming complete is in your home directory)

  • Is the surrounding code correct? I've found a syntax error in the surrounding code sometimes makes a big difference in this command, especially if it involves piping or new lines.

Hope this helps,

Mac Henni

  • complete is not a package (which could be checked with apt) or even a program (some programs have the same name as their package but many do not); it is a builtin feature of bash but not in zsh which OP appears to be using. Commented Sep 2, 2022 at 4:15

Thank you all for your help.

I used de apt show complete and looked for the COMPLETE command and it does not exist and is not installed.

But I found the file asdf.bash in /home/gustavo/.asdf/completions/asdf.bash and removed the offending statement. This made the message stop appearing.

  • As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.
    – Community Bot
    Commented Apr 10, 2022 at 15:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .