-
Notifications
You must be signed in to change notification settings - Fork 0
/
aliases
73 lines (53 loc) · 1.78 KB
/
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
# directory listing and navigation
alias ls='ls --color=auto'
alias ll='ls -l --color=always -h'
alias la='ls -la --color=always -h'
alias p='pushd $@ > /dev/null'
alias o='popd > /dev/null'
alias ..='p ..'
alias ...='p ../..'
# color output for grep
alias grep='grep --colour=auto'
alias zgrep='zgrep --colour=always'
# disable X support
alias vi='vi -X'
# run vim as root
alias svi='sudo vi'
# use login shell
alias su='su -'
# colored unified diff
alias diff='colordiff -u'
# always show human readable values
alias df='df -h'
# optimized dmesg output
alias dmesg='dmesg -L -H'
# tmux 256 color support
alias tmux='TERM=xterm-256color tmux'
# run svn diff with meld
alias sd='svn diff --diff-cmd ~/bin/svn-diff-meld'
# add all new files to svn
alias svn-add-all-new="svn status | grep ^? | sed s/?// | xargs svn add"
# remove all missing files from svn
alias svn-del-all-missing="svn status | grep ^! | sed s/\!// | xargs svn del"
# emerge shortcuts (useful for root)
alias e='emerge'
alias s='eix-sync'
alias u='emerge -avuND world'
alias dc='emerge --depclean -av'
# tailf was removed in util-linux 2.30
alias tailf='tail -f'
# tailf mail log file
alias tm='tail -f /var/log/mail'
# search also for hidden and ignored files/dirs
alias fda='fd -IH'
# cat and less with syntax highlighting
alias ccat='pygmentize -g -f 256 -O style=native'
function cless() {
pygmentize -g -f 256 -O style=native "$1" | less -R
}
# quickly show HTTPS certificate details
alias check_certificate='sslscan --show-certificate --no-ciphersuites --no-compression --no-heartbleed --no-renegotiation'
# Remove all docker containers
alias docker_stop_all_containers='docker stop $(docker ps -aq)'
alias docker_remove_all_containers='docker rm $(docker ps -aq)'
[[ -f ~/.dotfiles/aliases.local ]] && . ~/.dotfiles/aliases.local