Compare commits

...

2 Commits

Author SHA1 Message Date
Ray Elliott a9654b9d75 add bulk-rename alias 2020-06-30 16:58:34 +01:00
Ray Elliott d114544614 add cdlf and lfcd functions 2020-06-30 16:57:45 +01:00
1 changed files with 13 additions and 1 deletions

View File

@ -8,6 +8,7 @@ alias la='ls -lha --group-directories-first --time-style=+"%d.%m.%Y %H:%M" --col
alias ll='ls -lh --group-directories-first --time-style=+"%d.%m.%Y %H:%M" --color=auto -F' alias ll='ls -lh --group-directories-first --time-style=+"%d.%m.%Y %H:%M" --color=auto -F'
alias ls='ls --color=auto -h' alias ls='ls --color=auto -h'
alias bulk-rename='vimv'
alias cp='cp -i' alias cp='cp -i'
alias df='df -h' alias df='df -h'
@ -61,9 +62,20 @@ function npm {
# lf gets confused by TERMINFO env var when running in tmux # lf gets confused by TERMINFO env var when running in tmux
# https://github.com/gokcehan/lf/issues/138#issuecomment-464477665 # https://github.com/gokcehan/lf/issues/138#issuecomment-464477665
if [ -n "$TERMINFO" ] ; then if [ -n "$TERMINFO" ] ; then
alias lf="TERMINFO= lf" alias lf="TERMINFO= lf -last-dir-path=$HOME/.cache/lf-last-dir"
else
alias lf="lf -last-dir-path=$HOME/.cache/lf-last-dir"
fi fi
cdlf() {
cd "$(cat $HOME/.cache/lf-last-dir)"
}
lfcd() {
lf -last-dir-path="$HOME"/.cache/lf-last-dir
cdlf
}
# functions # functions
# $1 - output directory # $1 - output directory
# $2 - size # $2 - size