added moveto function in lf

This commit is contained in:
krolyxon 2022-07-17 22:42:44 +05:30
parent f55f92fb19
commit e8219bd2a2
3 changed files with 25 additions and 4 deletions

View File

@ -52,15 +52,25 @@ cmd delete ${{
[ $ans = "y" ] && rm -rf -- $fx
}}
cmd moveto ${{
clear; tput cup $(($(tput lines)/3)); tput bold
set -f
clear; echo "Move to where?"
dest=$(cat ~/.config/lf/mvdirs | fzf )
for x in $fx; do
eval mv -iv \"$x\" \"$dest\"
done &&
notify-send "🚚 File(s) moved." "File(s) moved to $dest."
}}
cmd genwall "$1"
cmd bulkrename $vidir
# Bindings
map <c-f> $lf -remote "send $id select \"$(fzf)\""
map J $lf -remote "send $id cd $(sed -e 's/\s*#.*//' -e '/^$/d' -e 's/^\S*\s*//' ${XDG_CONFIG_HOME:-$HOME/.config}/shell/bm-dirs | fzf)"
map D delete
map p paste
map dd cut
map M moveto
map yy copy
map H top
map E extract
@ -97,4 +107,5 @@ map gc cd ~/.config
map gr cd ~/code/repos
map gv cd ~/vids/
map gm cd ~/media/movies
map gM cd ~/media
map gs cd ~/.local/bin

7
.config/lf/mvdirs Normal file
View File

@ -0,0 +1,7 @@
$HOME/dl
$HOME/dox
$HOME/music
$HOME/movies
$HOME/vids
$HOME/pix
$HOME/pix/ss

View File

@ -12,7 +12,7 @@ fate -> a power that is believed to control what happens in the future
established -> accepted or followed by many people
compelled -> forced to do
abundant -> existing or occuring in large ammounts
bias -> a tendency to believe that some people,idias, etc are better than others useually results in treating some people unfairly
bias -> a tendency to believe that some people,idias, etc are better than others usually results in treating some people unfairly
desperate -> feeling or showing a hopeless sense taht a situation is so bad as to be impossible to deal with
iteration -> the repetition of a process or utterance
cope -> deal with something difficult
@ -65,7 +65,7 @@ derive -> obtain something from (a specified source)
sceptical -> not easily convinced; having doubts or reservations
psyched -> excited and full of anticipation
faucet -> a tap, "nal" in hindi
duress -> threats, violence, constrains, or other actions used to coerce someone into doing something against theri will or better judgement
duress -> threats, violence, constrains, or other actions used to coerce someone into doing something against their will or better judgement
detriment -> the state of being harmed or damaged
alleviate -> make (suffering, deficiency, or a problem) less severe
sentient -> able to perceive or feel things
@ -80,3 +80,6 @@ analogy -> a comparison between one thing and anotherm, typicall for the purpose
contagious -> spread from one person or orgranism to another, typically by direct contact
leconic -> a person who uses very few words
petulant -> a person who is rude and acts childish
monologue -> a long speech by one actor in a play or a film
apprehension -> anziety or fear that something bad or unpleasant will happen
reprise -> a repeated passage in music