-
Notifications
You must be signed in to change notification settings - Fork 2
/
bash_aliases
67 lines (53 loc) · 1.32 KB
/
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
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
#lookup wlan ip adress
alias wan_add=' ifconfig | sed -n '18p' | grep -oP "(\d{3}[.])+\d+" | grep -m 1 -oP "(\d{3}[.])+\d+" '
# system
alias pd='pushd'
alias PD='popd'
# Folder aliases
alias des='pd ~/Desktop'
alias doc='pd ~/Documents'
alias dow='pd ~/Downloads'
alias mus='pd ~/Music'
alias pic='pd ~/Pictures'
alias pub='pd ~/Public'
alias tem='pd ~/Templates'
alias vid='pd ~/Videos'
# git aliases
alias g='git'
alias g_='g status'
alias gc='g commit -m '
alias ga='g add '
alias gA='g add .'
alias gt='g tag '
alias gp='g push'
alias gP='g pull '
modified=$(g_ | grep -m 1 -oP "modified:(\s+\w+)")
last_tag=$(gt | sed -n '$p')
alias g-='gA && gc "$last_tag:$modified, $1" && echo -e "last tag: $last_tag" '
alias g+='gt $1 && gp'
# bash
alias r='. ~/.bashrc'
alias w='which'
alias m='man'
alias brn='nano -l ~/.bashrc'
alias ban='nano -l ~/.bash_aliases'
alias br='vim -o ~/.bashrc'
alias ba='vim -o ~/.bash_aliases'
# apt
alias xudo='sudo'
alias xapt='sudo apt install -yf '
# python3 aliases
alias py3='python3'
alias py3u='py3 -m unittest '
alias pyt='pytest '
alias pv='source venv/bin/activate'
# pywal
alias cw='py3 -m pywal -i'
# screenshot
alias x='import'
# Open Nano with line numbers
alias nano='nano -l'
# alias for clear terminal, using dos cls
alias cl='clear'
alias ch='cl && history -c && cl'
# Programs aliases