-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.bash_alias
82 lines (69 loc) · 2.45 KB
/
.bash_alias
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
# Various aliases
#
# - ABorgna
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'
alias mkdir='mkdir -p' # -> Prevents accidentally clobbering files.
alias h='history'
alias j='jobs -l'
alias ..='cd ..'
alias cls='clear' # C-l works too if you are not in tmux
# Conditional aliases (defaults must be escaped or else the alias will be called)
alias vim='runDefault nvim \\vim'
#alias syn='synergyc --no-restart --enable-crypto 192.168.250.200'
# Tmux
alias tm='~/.dots/bin/tm'
alias ta='tmux attach'
alias tns='tmux new-session -s'
# Pretty-print of some PATH variables:
alias path='echo -e ${PATH//:/\\n}'
alias libpath='echo -e ${LD_LIBRARY_PATH//:/\\n}'
# Makes a more readable output.
alias du='du -kh'
alias du1='du -kh -d1 | sort -h'
alias df='df -kTh'
alias free='free -h'
alias dd='dd status=progress'
# Compilers
function rung++ () { g++ -g -O2 -std=gnu++11 -o /tmp/$1.o $1 && /tmp/$1.o; }
alias watchmake='while true; do make --silent; sleep 1; done'
# Randoms
alias cloak='history -d $((HISTCMD-1)) &&'
alias c='cloak'
alias clk='tty-clock -c -C 7 -d 40000000'
alias ftn='fortune -ec'
alias music='ncmpcpp'
alias mpdrestart='sudo mpd --kill; mpd'
alias tt='sublimetext'
alias weather='weather -m SABE'
alias minicom='minicom -c'
alias cal='cal -3'
alias battlenet='WINEARCH=win32 wine .wine/drive_c/Program\ Files/Battle.net/Battle.net.exe'
alias ranger='source ranger'
alias egrep='grep -E'
# The ls family
# Add colors for filetype and human-readable sizes
alias l='command ls -hp --color --group-directories-first'
# Directories first, with alphanumeric sorting:
alias ll='l -lAcv'
alias ls="l -lv"
alias la='l -A' # Show hidden files.
alias lx='l -lXB' # Sort by extension.
alias lk='l -lSr' # Sort by size, biggest last.
alias lt='l -ltr' # Sort by date, most recent last.
alias lc='l -ltcr' # Sort by/show change time,most recent last.
alias lu='l -ltur' # Sort by/show access time,most recent last.
alias lr='ll -R' # Recursive ls.
alias tree='tree -Csuh' # Nice alternative to 'recursive ls' ...
# Swap key bindings, and toggle caps lock
alias aoe='setxkbmap us intl'
alias asd='setxkbmap us dvp -option "ctrl:nocaps,compose:ralt"'
alias CAPS='xdotool key Caps_Lock'
# Use ghc installed by stack
#alias ghc='stack ghc'
#alias ghci='stack ghci'
alias bazelt='bazel test --test_output=streamed'
function ghciwith () {
nix-shell -p "haskellPackages.ghcWithPackages (pkgs: with pkgs; [$*])" --run ghci
}