3

When using the terminal to navigate through my files I was used to be able to type

cd .. TAB where the TAB would add the / at the end of the .. and I could just continue typing. Now, on big sur, this does not work anymore. When I type cd .. and TAB the screen just flashes once and that's it, I always have to type the /

Can anybody help how to get the old behavior?

My .zshrc file

source /opt/homebrew/opt/chruby/share/chruby/chruby.sh source /opt/homebrew/opt/chruby/share/chruby/auto.sh export PATH=/opt/homebrew/bin:$PATH if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi 
7
  • 2
    Does this help? –superuser.com/q/277019, stackoverflow.com/q/564648 Commented Jun 23, 2021 at 7:54
  • 1
    Which shell are you using (bash or zsh)? Does it happen with all directories or only some? Commented Jun 23, 2021 at 7:56
  • zsh, it happens with all directories Commented Jun 23, 2021 at 8:14
  • Did you have any custom zsh settings before or after the update? Can you add your .zshrc file? Commented Jun 23, 2021 at 9:22
  • 1
    Added the .zshrc file Commented Jun 23, 2021 at 9:52

1 Answer 1

3

Zsh doesn't consider . or .. to be useful completions by default. For example cd .Tab offers hidden directories but not the special directories . and ... This is a difference from bash.

You can enable . and .. as completion by configuring the special-dirs completion style. This requires the “new” completion system, i.e. with a call to compinit in your .zshrc (possibly via some zsh configuration framework).

zstyle -e ':completion:*' special-dirs true 

Or, to complete .. but not .:

zstyle -e ':completion:*' special-dirs .. 

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.