change lf shortcut file
This commit is contained in:
parent
d99af87acd
commit
a0c5536c3d
|
@ -249,7 +249,7 @@ map -m fzf 'Marks' 'cat $XDG_DATA_HOME/lf/marks 2>/dev/null' ':' '2' '85%' '^'
|
|||
map -f fzf 'Files' 'find -L $PWD' ':' '1' '50%'
|
||||
map -g find_word
|
||||
map "'" mark-load
|
||||
map '"' mark-save
|
||||
map '"' mark-remove
|
||||
map "$" shell
|
||||
map "!" shell-wait
|
||||
map "&" shell-async
|
||||
|
|
|
@ -5,23 +5,23 @@ bmdirs="$XDG_CONFIG_HOME/directories"
|
|||
|
||||
# Outputs
|
||||
zsh_named_dirs="$ZDOTDIR/configs/hashes"
|
||||
lf_dirs="$XDG_DATA_HOME/lf/dirs"
|
||||
lf_dirs="$XDG_DATA_HOME/lf/shortcuts"
|
||||
|
||||
# TODO: Finish this function LOL
|
||||
find_marker() {
|
||||
file=$1
|
||||
for marker in \
|
||||
"# @SHORTCUTS@" \
|
||||
"-- @SHORTCUTS@" \
|
||||
"// @SHORTCUTS@" \
|
||||
"/* @SHORTCUTS@ */"; do
|
||||
file=$(grep -xn "$marker" "$file")
|
||||
if [ -n "$file" ]; then
|
||||
echo "$file"
|
||||
return
|
||||
fi
|
||||
done
|
||||
}
|
||||
# find_marker() {
|
||||
# file=$1
|
||||
# for marker in \
|
||||
# "# @SHORTCUTS@" \
|
||||
# "-- @SHORTCUTS@" \
|
||||
# "// @SHORTCUTS@" \
|
||||
# "/* @SHORTCUTS@ */"; do
|
||||
# file=$(grep -xn "$marker" "$file")
|
||||
# if [ -n "$file" ]; then
|
||||
# echo "$file"
|
||||
# return
|
||||
# fi
|
||||
# done
|
||||
# }
|
||||
|
||||
zsh() {
|
||||
xargs printf "hash -d %s=%s\n"
|
||||
|
@ -39,7 +39,7 @@ write_dirs_tmp() {
|
|||
path=$(eval "echo $path")
|
||||
|
||||
printf "hash -d %s=%s\n" "$shortcut" "$path" >>"/tmp/shortcuts/zsh_named_dirs"
|
||||
printf "%s\t%s\n" "$shortcut" "$path" >>"/tmp/shortcuts/lf_dirs"
|
||||
printf "%s:%s\n" "$shortcut" "$path" >>"/tmp/shortcuts/lf_dirs"
|
||||
done
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue