-
Notifications
You must be signed in to change notification settings - Fork 0
/
.bash_aliases
37 lines (21 loc) · 991 Bytes
/
.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
#!/usr/bin/env bash
# remove .DS_Store files
alias ds="sudo find -x . -iname '.DS_Store'"
# git push
alias gitpush="git push -u origin master"
# Undo gitpush
alias gitunpush="git push -f origin HEAD^:master"
# IP addresses
alias ip="dig +short myip.opendns.com @resolver1.opendns.com"
alias ips="ifconfig -a | perl -nle'/(\d+\.\d+\.\d+\.\d+)/ && print $1'"
# list files - F: flag directories, executables, symlinks, etc l: long format A: all files except . and .. G: colorize output
alias ll="ls -FlAG"
# safety first rm
alias rm="rm -i"
# add blank space to dock
alias space="defaults write com.apple.dock persistent-apps -array-add '{tile-data={}; tile-type=\"spacer-tile\";}';Killall Dock"
# alias to add a space-tile to the Dock
# Left side
# defaults write com.apple.dock persistent-apps -array-add '{tile-data={}; tile-type="spacer-tile";}'
# Right Side
# defaults write com.apple.dock persistent-others -array-add '{tile-data={}; tile-type="spacer-tile";}'