-
Notifications
You must be signed in to change notification settings - Fork 0
/
aliases
41 lines (33 loc) · 799 Bytes
/
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
#!/usr/bin/env bash
# Some ls aliases
if [[ "$OSTYPE" == "linux"* ]]; then
alias ls='ls -F --color=auto --group-directories-first'
alias la='ls -A'
alias ll='ls -l'
elif [[ "$OSTYPE" == "darwin"* ]]; then
alias ls='ls -FG'
alias la='ls -A'
alias ll='ls -l'
fi
alias grep=' grep --color=auto'
alias fgrep='fgrep --color=auto'
alias egrep='egrep --color=auto'
# Common commands
alias mv='mv -vi'
alias cp='cp -vi'
alias ln='ln -v'
alias du='du -h'
alias rg='rg -i'
alias mkdir='mkdir -pv'
alias vtop='vtop --theme brew'
if command -v nvim &> /dev/null; then
alias e=nvim
fi
if command -v grm &> /dev/null; then
alias rm='grm -vI'
alias del='gmv -t ~/.Trash'
elif [[ "$OSTYPE" == "linux"* ]]; then
alias rm='rm -vI'
alias del='mv -t ~/.Trash'
fi
# vim: ft=bash sw=2 ts=2