2023-07-22 14:46:26 +02:00
|
|
|
# just for security and for fun because i have typing -rf every time
|
|
|
|
alias cp='cp -v'
|
|
|
|
alias mv='mv -v'
|
|
|
|
alias rm='rm -v'
|
2024-02-20 15:49:52 +01:00
|
|
|
alias ff='fasttyper'
|
2023-07-22 14:46:26 +02:00
|
|
|
|
2024-02-20 15:49:52 +01:00
|
|
|
# exit
|
2023-07-22 14:46:26 +02:00
|
|
|
alias e='exit'
|
2024-02-20 15:49:52 +01:00
|
|
|
|
|
|
|
# program shortcuts
|
2023-07-22 14:46:26 +02:00
|
|
|
alias grep='grep --color=auto'
|
2024-02-20 15:49:52 +01:00
|
|
|
|
|
|
|
# ls
|
2023-07-22 14:46:26 +02:00
|
|
|
alias ls='exa --icons -g'
|
|
|
|
alias ll='ls -lh'
|
|
|
|
alias lls='ls -lhrs modified'
|
|
|
|
alias la='ls -a'
|
|
|
|
alias lla='ls -lha'
|
|
|
|
alias l='ls'
|
2024-02-20 15:49:52 +01:00
|
|
|
lst() { exa --no-icons --sort=time | head --lines=1; }
|
|
|
|
|
|
|
|
# python
|
2023-07-22 14:46:26 +02:00
|
|
|
alias py='python3'
|
|
|
|
alias py3='python3'
|
|
|
|
alias pip='python3 -m pip'
|
|
|
|
alias ipy='ipython --TerminalInteractiveShell.editing_mode=vi --TerminalInteractiveShell.timeoutlen=0.2'
|
2024-02-20 15:49:52 +01:00
|
|
|
|
|
|
|
# vim
|
2023-07-22 14:46:26 +02:00
|
|
|
alias vim='nvim'
|
|
|
|
alias v='vim'
|
|
|
|
alias vv='vifm'
|
2024-02-20 15:49:52 +01:00
|
|
|
|
|
|
|
# kitty
|
2023-07-22 14:46:26 +02:00
|
|
|
if [ "$TERM" = "xterm-kitty" ]; then
|
|
|
|
alias kssh='kitty +kitten ssh'
|
|
|
|
fi
|
|
|
|
|
2024-02-20 15:49:52 +01:00
|
|
|
# copy piped to clipboard
|
|
|
|
cpy() { py -c "import sys, pyperclip; pyperclip.copy(sys.stdin.read().strip())"; }
|
|
|
|
|
|
|
|
# history
|
2023-07-22 14:46:26 +02:00
|
|
|
hlst() { history | tail --lines=1 | cut -d " " -f 4-; }
|
|
|
|
lstc() { lst | cpy; }
|
|
|
|
hlstc() { hlst | cpy; }
|