# after calling ^P.
bindkey -a '^N' history-beginning-search-forward
+# Automatically push cd-ed directories on the directory stack.
+setopt autopushd
+# Don't push duplicates on the directory stack.
+setopt pushdignoredups
+# Exchange the meaning of + and - when specifying a directory on the stack.
+# This way cd -<Tab> lists the last used directory first, which is more
+# natural because cd - goes to the last directory.
+setopt pushdminus
+
# PROMPT SETTINGS
# Don't complete unwanted files with Vim. Thanks to Nomexous in #zsh on
# Freenode (2010-06-06 04:54 CEST). See below for a way to complete them.
-zstyle ':completion:*:*:vim:*:all-files' ignored-patterns '*.aux' '*.log' \
- '*.pdf' '*.class'
+zstyle ':completion:*:*:vim:*:all-files' ignored-patterns \
+ '*.aux' '*.log' '*.pdf' \
+ '*.class'
# Provide a fallback completer which always completes files. Useful when Zsh's
# completion is too "smart". Thanks to Frank Terbeck <ft@bewatermyfriend.org>