Update .config/sheldon/plugins.toml

Update .config/zsh/env.zsh
Add .config/zsh/files/functions.zsh
Remove .config/zsh/files/keybinds.zsh
Remove .config/zsh/files/transfer.zsh
Update .config/zsh/rc.zsh
This commit is contained in:
eeleater 2022-12-20 16:45:56 +01:00
parent 27a779ca15
commit a5c3567d85
6 changed files with 47 additions and 50 deletions

View file

@ -0,0 +1,15 @@
pet_select () {
BUFFER=$(pet search --query "$LBUFFER")
CURSOR=$#BUFFER
zle redisplay
}
zle -N pet_select
bindkey '^l' pet_select
run_ranger () {
echo
ranger < $TTY
zle redisplay
}
zle -N run_ranger
bindkey '^f' run_ranger

View file

@ -1,7 +0,0 @@
run_ranger () { echo; ranger < $TTY; zle redisplay }
zle -N run_ranger
bindkey '^f' run_ranger
pet_select () { BUFFER=$(pet search --query "$LBUFFER"); CURSOR=$#BUFFER; zle redisplay }
zle -N pet_select
bindkey '^l' pet_select

View file

@ -1,26 +0,0 @@
transfer () {
if test $# -eq 0; then
echo "No arguments specified.\nUsage:\n transfer <file|directory>\n ... | transfer <file_name>">&2
return 1
fi
if tty -s; then
file="$1"
file_name=$(basename "$file")
if test ! -e "$file"; then
echo "$file: No such file or directory">&2
return 1
fi
if test -d "$file"; then
file_name="$file_name.zip"
(cd "$file" && zip -r -q - .) | curl --progress-bar --upload-file "-" "https://transfer.sh/$file_name" | tee /dev/null
else
cat "$file" | curl --progress-bar --upload-file "-" "https://transfer.sh/$file_name" | tee /dev/null
fi
else
file_name=$1
curl --progress-bar --upload-file "-" "https://transfer.sh/$file_name" | tee /dev/null
fi
}