-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaliases.zsh
130 lines (111 loc) · 2.57 KB
/
aliases.zsh
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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
#!/bin/zsh
source "${ZSH_DIR}/utils.zsh"
unalias _ 2 &>/dev/null
# General
alias psg="ps aux | grep"
alias bctl="bluetoothctl"
alias px="pulsemixer"
# Neovim
alias n="nvim"
alias nn="n ${NVIM_DIR}/init.vim"
alias ne="n ${ZSH_DIR}/env.zsh"
alias na="n ${ZSH_DIR}/aliases.zsh"
alias sn="sudo -E nvim"
# PostgreSQL
alias pgc="clear && pgcli postgres postgres"
# OS Query
alias oj='() { osqueryi --json "$1" | jq }'
alias soj='() { sudo osqueryi --json "$1" | jq }'
# Virt manager
alias vs="sudo -E virsh"
# List device blocks
alias lb="lsblk -o name,size,fstype,mountpoints,uuid"
# Pacman package manager
alias pm="sudo pacman"
alias pmu="pm -Syyu --noconfirm"
alias pmi="pm -S --noconfirm"
alias pmr="pm -Rvns --noconfirm"
alias pms='() { pm -Ss $1 || yms $1 }'
alias pmq="pm -Qs"
alias pmqq="pmq -q"
# Yay package manager
alias ymu="yay -Syyu --noconfirm"
alias ymi="yay -S --noconfirm"
alias yms="yay -Ss"
# SystemD
alias sc="sudo systemctl"
alias scu="systemctl --user"
alias scs="sc start"
alias sco="sc stop"
alias sct="sc status"
alias sce="sc enable"
alias scd="sc disable"
alias scr="sc restart"
alias sces="sce && scs"
alias scou="scu stop"
alias scsu="scu start"
alias sctu="scu status"
alias scru="scu restart"
alias sceu="scu enable"
alias scdu="scu disable"
# git
alias gacam="ga . && gcam"
alias ggpnv="ggpush --no-verify"
alias gce="g commit --amend"
alias gcr="g conflicts --relative"
# Spotify
alias sp="spotify_player"
alias spr="scru spotifyd && sp"
# Kubectl
alias km="kc minikube"
alias kme="km explain"
alias kml="km logs"
alias kmg="km get"
alias kmi="km describe"
alias kmd="km delete"
alias vk="vipe | xargs -I % kubectl"
# Minikube
alias mk="minikube"
alias mks="mk start"
alias mko="mk stop"
alias mkp="mk pause"
alias mki="mk status"
alias mkd="mk delete"
alias mkda"mkd --all --purge"
# Terraform
alias tf="terraform"
alias tfi="tf init"
alias tfp="tf plan"
alias tfa="tf apply"
alias tfaa="tfa -auto-approve"
# ZSH
alias zs="source $ZSH_DIR/*.zsh"
alias zc="n $ZSH_DIR/init.zsh"
alias ze="n $ZSH_DIR/env.zsh"
alias za="n $ZSH_DIR/aliases.zsh"
alias zu="n $ZSH_DIR/utils.zsh"
# Docker
alias d="sudo docker"
alias dr="d run"
alias drsh="dr --entrypoint sh"
alias dp="d pull"
alias dc="d container"
alias di="d image"
alias dii="d images"
alias dps="d ps"
alias dco="dc stop"
alias dcs="dc start"
alias dcr="dc run"
alias dck="dc kill"
alias dcl="dc logs"
alias dcls="dc ls"
alias stopc='dco $(dcl -lq)'
# Veracrypt
# alias vc="veracrypt"
# alias vcd="vc -d"
# alias vcl="vc -l"
# alias vcm='\
# vc \
# --non-interactive \
# -p "$(lpass show --password 1215307261831005367)" \
# '