-
Notifications
You must be signed in to change notification settings - Fork 0
/
aliases
54 lines (41 loc) · 1005 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
42
43
44
45
46
47
48
49
50
51
52
53
54
###########
# Aliases #
###########
# Make
alias m='make'
# Trash-CLI
# alias t='trash-put'
# Kill process using fuzzy selector
fkill () {
ps aux | fzy | awk '{ print $2 }' | xargs kill
}
# Serve the current directory as HTTP
alias serve='ruby -run -e httpd . -p 8000'
# ripgrep
alias grep='rg'
# xsel
alias copy='xsel -ib'
alias paste='xsel -ob'
# eza
alias ls='eza'
# fd
alias find='fd'
# Git
alias gcwip='git add --all . && git commit -m "[skip-ci] WIP"'
alias gu='git --no-pager log -1; git reset --soft HEAD~1'
alias gca='git commit --amend --no-edit'
alias gs='git stash'
alias gsp='git stash pop'
alias grh='git reset --hard'
# Git fuzzy switch branches
fgc () {
git checkout $(git branch | fzf)
}
# Rails fuzzy tasks
function frt() {
eval $(rails -T | tail -n +2 | fzf)
}
# capture the output of a command so it can be retrieved with ret
alias cap='tee /tmp/capture.out;'
# return the output of the most recent command that was captured by cap
alias ret='cat /tmp/capture.out;'