-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.aliases
55 lines (49 loc) · 1.56 KB
/
.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# ls -X: sort by type
# -F: append file type
# -l: use a long listing format
alias ls='ls -1 -XF --group-directories-first --color'
alias l='ls -lFX --group-directories-first --color'
alias ll='ls -laX --group-directories-first --color'
alias c='clear'
alias hist="vi $HOME/.zsh_history"
alias diff='diff --color -rup'
shell=$(ps -p$$ -ocmd=)
if [[ $shell =~ "zsh" ]]; then
alias -g G='| grep'
alias -g R='| rg'
alias -g L='| less'
alias -g S='| subl'
alias -g X='| xargs'
alias -g C='| wc -l'
alias -g N='&> /dev/null'
alias -g B='> /home/erik/.cache/tmp.log'
fi
# default oh-mh-zsh aliases I use a lot
alias gms='git merge --squash'
alias gs='git status'
alias gd='git diff'
alias gco='git checkout'
alias gcd='git checkout dev'
alias gcm='git checkout main'
alias gcms='git checkout master'
alias gst='git stash'
alias gstl='git stash list'
alias grc='git reset --hard && git clean -f'
alias grhh='git reset --hard'
alias gfs='git fsck'
alias gb='git --no-pager branch'
alias gba='git --no-pager branch -a'
alias grt='cd "$(git rev-parse --show-toplevel)"'
# misc
alias vimrc='vim ~/.vimrc'
alias zshrc='vim ~/.zshrc'
alias tmuxrc='vim ~/.tmux.conf'
alias aliases='vim ~/.dotfiles/.aliases'
alias chrome='google-chrome-stable'
alias pac="pacman -Slq | fzf --multi --preview 'pacman -Si {1}' | xargs -ro sudo pacman -S"
alias notes='code ~/Documents/VScode-Workspaces/notes.code-workspace'
alias sc2='code ~/Documents/VScode-Workspaces/sc2.code-workspace'
alias logs='vim /home/erik/.cache/tmp.log'
alias blog='vim ~/Notes/tmp/blog.md'
alias vi='\vim'
alias vim='vim -c vnew'