-
Notifications
You must be signed in to change notification settings - Fork 1
/
aliases.sh
67 lines (51 loc) · 1.21 KB
/
aliases.sh
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
# shell functions
function take {
mkdir -p $1
cd $1
}
function osync {
cd ~/Documents/obsidian-vault
git add . && git commit -m "obsidian update: $(date)"
git push -u origin HEAD
}
function gwa {
if [ "$#" -ne 2 ]; then
echo "Usage: gwa <feature type> <branch name>"
return
fi
local feature_type=$1
local branch_name=$2
git worktree add -b $feature_type/$branch_name .worktrees/$feature_type/$branch_name
}
function gwb {
cd ../../..
}
function newsess {
tmux new -s $1 -d
}
function sql-spad {
mkdir -p /tmp/sqlpad
touch /tmp/sqlpad/$(date +%s).sql
nvim /tmp/sqlpad/$(date +%s).sql
}
# aliases
alias bat='bat -p'
alias ls='eza'
alias ll='eza -l'
alias el="eza -l --icons --git -a"
alias elt="eza --tree --level=3 --long --icons --git"
alias cdr='cd $(git rev-parse --show-toplevel)'
alias rustbook='rustup doc --book'
alias gcommit='~/dotfiles/scripts/gum/better_commit.sh'
alias gswitch='~/dotfiles/scripts/gum/better_switch.sh'
alias c=clear
alias t=tmux
alias wrename='tmux rename-window'
alias ktl=kubectl
alias gowork='~/go/src/github.com/Masamerc/'
alias k=kubectl
alias lg=lazygit
alias vim=nvim
alias vi=nvim
alias v=nvim
alias gcl="gcloud"