-
Notifications
You must be signed in to change notification settings - Fork 0
/
.bashrc
46 lines (36 loc) · 1.01 KB
/
.bashrc
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
#
# ~/.bashrc
#
# If not running interactively, don't do anything
[[ $- != *i* ]] && return
alias grep='grep --color=auto'
alias ping='ping -c 4'
alias vim='vim -X'
# list - maintain order
alias ls='ls -F --color=auto'
alias la='ls -Ahil'
alias ll='ls -l'
# ask before foo
alias cp='cp -i'
alias ln='ln -i'
alias mv='mv -i'
# variable
export EDITOR='vim'
export PAGER='less'
export HISTCONTROL='ignoreboth:erasedups'
export HISTIGNORE='cd *:&:exit:history:l[asl]'
export HISTSIZE='100'
# misc
stty -ctlecho
# prompt KISS
PS1='>'
PS2='\\'
# external IP
myip() { dig myip.opendns.com @resolver1.opendns.com +short ;}
# cli pastebins
sprunge() { $@ | curl -F 'sprunge=<-' sprunge.us ;}
ix() { $@ | curl -F 'f:1=<-' ix.io ;}
clbin() { $@ | curl -F 'clbin=<-' https://clbin.com ;}
clbin-scrot() { scrot -e 'curl -F "clbin=@$f" https://clbin.com' ;}
# update AdBlock easylists
bollock() { wget https://easylist-downloads.adblockplus.org/{easy{list,privacy},fanboy-annoyance}.txt -nv -N -P $HOME/.local/share/luakit/adblock/ ;}