forked from mxaddict/dotfiles_archive_001
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.aliasrc
135 lines (114 loc) · 3.15 KB
/
.aliasrc
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
131
132
133
134
135
#!/bin/sh
# QUIT the TERMINAL VIM style!
alias :q=exit
alias :qa=exit
alias :wq=exit
# Some quick Aliases for IRC related things
alias irc='irssi'
alias irctor='torsocks irssi'
alias irc_gents='torsocks irssi -c fsociety7xkhgt6i.onion -p 6697'
alias irc_undernet='irssi -c undernet'
alias irc_freenode='irssi -c freenode'
# Aliases to enable color support for these
alias ls='ls --color=auto'
alias dir='dir --color=auto'
alias vdir='vdir --color=auto'
alias grep='grep --color=auto'
alias fgrep='fgrep --color=auto'
alias egrep='egrep --color=auto'
# some more ls aliases
alias ll='ls -alFv --group-directories-first'
alias la='ls -A'
alias l='ls -CF'
alias lt='ll -t'
# I want v to open vi and vi to open vim
alias v=vim
alias vi=nvim
# I need some aliases for tmuxp
alias tp='tmuxp'
alias tpl='tp load'
alias tpe='tp edit'
alias tpkill='tmux kill-server'
# payrent ide
alias pay='tpl -y payrent'
alias nav='tpl -y nav'
# Add some GIT aliases for fixing typos
alias fat='echo "Hey there fat fingers!!!\n" && git'
alias got='fat'
alias gto='fat'
alias gti='fat'
alias gd='git diff'
alias ga='git add'
alias gdf='git difftool'
alias gpr='git pull --rebase'
alias gf='git fetch'
alias gs='git status'
alias gc='git commit'
# Add alias for typo of mkdir
alias mkdit='mkdir'
# Some helpers
alias zconfig="vi $HOME/.zshrc"
alias reload="source $HOME/.shrc"
alias paths="sed 's/:/\n/g' <<< \"$PATH\""
alias ag='ag --hidden'
# Check if we have an debian based system
if [ $(command -v apt-get) ]
then
# Alias for system package manager
alias mxpacman='sudo apt-get'
fi
# Check if we have an ubuntu based system
if [ $(command -v apt) ]
then
# Alias for system package manager
alias mxpacman='sudo apt'
fi
# Some system package management aliases
alias mxupdate='mxpacman update'
alias mxinstall='mxpacman install'
alias mxupgrade='mxpacman upgrade'
alias mxdistupgrade='mxpacman dist-upgrade'
alias mxautoclean='mxpacman autoclean'
alias mxautoremove='mxpacman autoremove'
# Alias for our mxmaintenance helper
alias mxmaintenance='mxupdate && mxupgrade -y && mxdistupgrade -y && mxautoclean -y && mxautoremove -y'
# If nala is installed overwrite maintenance aliases
if [ $(command -v nala) ]
then
alias mxpacman='sudo nala'
alias mxupdate='mxpacman update'
alias mxinstall='mxpacman install'
alias mxupgrade='mxpacman upgrade'
alias mxautoremove='mxpacman autoremove'
alias mxmaintenance='mxupdate && mxupgrade -y && mxautoremove'
fi
alias mxshutdown='mxmaintenance && shutdown now'
# Alias for easy clipping
if [ $(command -v xsel) ]
then
alias clip='xsel -b'
fi
if [ $(command -v scrcpy) ]
then
alias rs8='nohup scrcpy -m 1080 --window-height 750 -S &'
alias rs21='nohup scrcpy -b2M -m800 -S &'
alias rphone='nohup scrcpy --window-height 900 -S &'
alias rwphone='nohup scrcpy -b2M --window-height 900 -S &'
fi
alias gdesc='for line in $(git branch); do
description=$(git config branch.$line.description)
if [ -n "$description" ]; then
echo "\n---"
echo "$line $description"
fi
done'
if [ $(command -v payrent-dump) ]
then
alias pd='payrent-dump'
alias pdl='pd -l payrent-live'
alias pdd='pd -l payrent-dev'
fi
if [ $(command -v docker-compose) ]
then
alias dco='docker compose'
fi