initial commit
This commit is contained in:
commit
4b266c97e9
21 files changed
+2797
No files matched your search
@@ -0,0 +1,21 @@
|
||||
# change the directory to last dir on exit
|
||||
# adapted from the similar script for ranger
|
||||
#
|
||||
# you need to add something like the following to your shell rc file (e.g. ~/.bashrc):
|
||||
#
|
||||
# LFSH="$GOPATH/src/github.com/gokcehan/lf/etc/lf.sh"
|
||||
# if [ -f "$LFSH" ]; then
|
||||
# source "$LFSH"
|
||||
# bind '"\C-o":"\C-ulf\C-m"'
|
||||
# fi
|
||||
#
|
||||
|
||||
lf () {
|
||||
tmp="$(mktemp)"
|
||||
command lf -last-dir-path="$tmp" "$@"
|
||||
if [ -f "$tmp" ]; then
|
||||
dir="$(cat "$tmp")"
|
||||
[ "$dir" != "$(pwd)" ] && cd "$dir"
|
||||
fi
|
||||
rm -f "$tmp"
|
||||
}
|
||||
Reference in new issue
Block a user