Skip to content

Commit 03059c6

Browse files
author
root
committed
Added in a server specific .bash_aliases. Very helpful on all the
servers.
1 parent 178660c commit 03059c6

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

.bash_aliases

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# All the aliases a sysadmin could want.
2+
3+
# Ever accidently remove something very important with rm? Let's fix that. Also, no -rf required for folders!
4+
rm () { mv $1 /tmp/Trash; }
5+
alias emptytrash="/bin/rm -rf /tmp/Trash/*"
6+
7+
# Apt stuff
8+
alias install="apt-get -y install "
9+
alias update="apt-get -y -q update"
10+
alias upgrade="apt-get -y -q update && apt-get -y -q upgrade"
11+
alias remove="apt-get -y remove"
12+
alias uninstall="apt-get -y remove"
13+
alias purge="sudo apt-get -y remove --purge"
14+
15+
# Handy git aliases
16+
alias ga="git add -A --ignore-errors"
17+
alias gc="git commit -a"
18+
alias gs="git status"
19+
alias gb="git branch"
20+
alias gp="git push origin"
21+
#Git feature branch
22+
gfb () { git checkout -b $1 develop; }
23+
#Merge feature branch
24+
gmfb () { git checkout develop; git merge --no-ff $1; git branch -d $1; git push origin develop; }
25+
26+

0 commit comments

Comments
 (0)