Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Ohmyzsh
Commits
a0a8ba66
Commit
a0a8ba66
authored
Feb 27, 2010
by
Matt Cable
Browse files
Initial pass at pesistant directory stack
parent
99f159e0
Changes
1
Show whitespace changes
Inline
Side-by-side
lib/dirspersist.zsh
0 → 100644
View file @
a0a8ba66
#!/bin/zsh
#
# Make the dirstack more persistant
#
# Run dirpersiststore in ~/.zlogout
dirpersiststore
()
{
dirs
-p
|
sed
's/ /\\ /g;s/^/pushd -q /;1!G;h;$!d;'
>
~/.zdirstore
}
dirpersistrestore
()
{
if
[
-f
~/.zdirstore
]
;
then
source
~/.zdirstore
fi
}
DIRSTACKSIZE
=
10
setopt autopushd pushdminus pushdsilent pushdtohome pushdignoredups
dirpersistrestore
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment