projects
/
grml-etc-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
7fffb76
)
zshrc: dirstack: skip for ZSH_SUBSHELL
author
Daniel Hahler
<git@thequod.de>
Wed, 4 May 2016 21:37:16 +0000
(23:37 +0200)
committer
Frank Terbeck
<ft@grml.org>
Fri, 6 May 2016 10:16:17 +0000
(12:16 +0200)
Otherwise `(cd foo)` would add `foo` to the stack, which is probably not
what you would expect.
etc/zsh/zshrc
patch
|
blob
|
history
diff --git
a/etc/zsh/zshrc
b/etc/zsh/zshrc
index
c03b614
..
84d37a9
100644
(file)
--- a/
etc/zsh/zshrc
+++ b/
etc/zsh/zshrc
@@
-1613,6
+1613,7
@@
if zstyle -T ':grml:chpwd:dirstack' enable; then
}
chpwd() {
}
chpwd() {
+ (( ZSH_SUBSHELL )) && return
(( $DIRSTACKSIZE <= 0 )) && return
[[ -z $DIRSTACKFILE ]] && return
grml_dirstack_filter $PWD && return
(( $DIRSTACKSIZE <= 0 )) && return
[[ -z $DIRSTACKFILE ]] && return
grml_dirstack_filter $PWD && return