-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.bash_aliases
31 lines (25 loc) · 893 Bytes
/
.bash_aliases
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# ls aliases
alias ls='ls --color="auto" --group-directories-first'
alias ll='ls -alFh'
alias la='ls -A'
# Add an "alert" alias for long running commands. Use like so:
# sleep 10; alert
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')" && (paplay /usr/share/sounds/freedesktop/stereo/complete.oga &)'
# Clipboard
alias c='xclip -selection clipboard'
alias p='xclip -o -selection clipboard'
# Get tmux and vim to play nicely
alias tmux='TERM=screen-256color tmux'
# Quick mercurial update
alias hglog='hg glog -l 12'
# All in one apt/snap update
alias update='(
sudo apt update &&
sudo apt upgrade &&
sudo apt autoremove &&
sudo snap refresh
)'
# Recursively remove all pyc files from current directory
function pyclean() {
sudo find . -name '*.pyc' -delete
}