-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathalias
108 lines (82 loc) · 2.25 KB
/
alias
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
## Common commands
alias grep='grep --color=auto'
alias ll='ls -ahlF'
alias vi='vim'
alias log='tail -f -n50 '
alias fn='find . -name'
alias reload!='. ~/.zshrc'
alias s='sudo '
alias sp='sudo env PATH=$PATH '
alias mirror='rsync -avh --delete'
alias secure='chmod go-rwx --preserve-root'
alias scert='openssl x509 -text -noout -in'
alias myip='curl icanhazip.com'
## Tools
# Ansible
alias ap='ansible-playbook'
# AWS
alias av='aws-vault --backend file'
alias avadd='aws-vault --backend file add'
alias avexec='aws-vault --backend file exec --assume-role-ttl=1h'
alias avlogin='aws-vault --backend file login'
alias avrm='aws-vault --backend file remove'
alias avde='if [[ ! -z "$AWS_VAULT" ]]; then exit; fi'
alias awsume='source awsume'
# Env
alias ev='env-vault --backend file'
alias evadd='env-vault --backend file add'
alias evexec='env-vault --backend file exec'
alias evedit='env-vault --backend file edit'
alias evls='env-vault --backend file ls'
alias evrm='env-vault --backend file remove'
alias evde='if [[ ! -z "$ENV_VAULT" ]]; then exit; fi'
# Docker
alias drun='docker run'
alias dstart='docker start'
alias dstop='docker stop'
alias dps='docker ps'
alias dpsa='docker ps --all'
alias drm='docker rm'
alias drmf='docker rm -f'
alias drmi='docker rmi'
alias dimg='docker images'
alias dpush='docker push'
alias dpull='docker pull'
alias dsh='docker run --rm -i -t'
alias dcmd='docker run --rm -i -v $(pwd):/tmp -w /tmp'
alias drsh='docker exec -t -i'
alias dc='docker-compose'
# Libreoffice
alias lo='libreoffice --norestore'
# Python
alias wo='workon'
alias de='deactivate'
alias mkve='mkvirtualenv'
alias rmve='rmvirtualenv'
alias lsve='lsvirtualenv -b'
# Vagrant
alias vup='vagrant up'
alias valt='vagrant halt'
alias vssh='vagrant ssh'
# Terraform
alias tfmt='terraform fmt'
## Monitoring
# Disk
alias df='df -h'
alias du='du -ch'
alias du1='du -ch --max-depth=1'
alias size='du -hs'
# Network
alias ports='ss -tulanp'
alias listen='sudo ss -plunt'
# Memory
alias meminfo='free -m -l -t -h'
# Processes
alias psmem='ps auxf | sort -nr -k 4'
alias psmem10='ps auxf | sort -nr -k 4 | head -10'
alias pscpu='ps auxf | sort -nr -k 3'
alias pscpu10='ps auxf | sort -nr -k 3 | head -10'
# CPU
alias cpuinfo='lscpu'
# xclip
alias cxclip='xclip -selection clipboard'