switch to chezmoi
This commit is contained in:
parent
3c5d00dbf3
commit
a8b0acd4db
76 changed files with 27 additions and 531 deletions
7
dot_config/private_fish/conf.d/globals.fish
Normal file
7
dot_config/private_fish/conf.d/globals.fish
Normal file
|
@ -0,0 +1,7 @@
|
|||
set -x LESS 'i n M R S'
|
||||
set -x PAGER less
|
||||
set -x EDITOR hx
|
||||
set -x TIME_STYLE long-iso
|
||||
set -x SSH_AUTH_SOCK "$XDG_RUNTIME_DIR/ssh-agent.socket"
|
||||
set -x ALTERNATE_EDITOR ""
|
||||
set -U fish_greeting
|
3
dot_config/private_fish/functions/atmux.fish
Normal file
3
dot_config/private_fish/functions/atmux.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function atmux
|
||||
tmux attach || tmux
|
||||
end
|
3
dot_config/private_fish/functions/diff.fish
Normal file
3
dot_config/private_fish/functions/diff.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function diff
|
||||
command diff --color $argv
|
||||
end
|
3
dot_config/private_fish/functions/g.fish
Normal file
3
dot_config/private_fish/functions/g.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function g
|
||||
command lazygit $argv
|
||||
end
|
3
dot_config/private_fish/functions/gci.fish
Normal file
3
dot_config/private_fish/functions/gci.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gci
|
||||
command git commit $argv
|
||||
end
|
3
dot_config/private_fish/functions/grep.fish
Normal file
3
dot_config/private_fish/functions/grep.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function grep
|
||||
command grep --color=auto $argv
|
||||
end
|
6
dot_config/private_fish/functions/greset.fish
Normal file
6
dot_config/private_fish/functions/greset.fish
Normal file
|
@ -0,0 +1,6 @@
|
|||
function greset
|
||||
read -P "OK to reset and clean teh repo?"\n -ln1 resp
|
||||
test "$resp" != y && return 0
|
||||
command git clean -fd
|
||||
command git reset --hard
|
||||
end
|
6
dot_config/private_fish/functions/groot.fish
Normal file
6
dot_config/private_fish/functions/groot.fish
Normal file
|
@ -0,0 +1,6 @@
|
|||
function groot
|
||||
set -l is_git_worktree (command git rev-parse --is-inside-work-tree)
|
||||
string match -qe 'true' "$is_git_worktree" || return
|
||||
set -l root (command git rev-parse --show-toplevel)
|
||||
test $status -eq 0 && cd $root
|
||||
end
|
3
dot_config/private_fish/functions/gsi.fish
Normal file
3
dot_config/private_fish/functions/gsi.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gsi
|
||||
termcompat tig status
|
||||
end
|
3
dot_config/private_fish/functions/gsl.fish
Normal file
3
dot_config/private_fish/functions/gsl.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gsl
|
||||
command git stash list $argv
|
||||
end
|
3
dot_config/private_fish/functions/gss.fish
Normal file
3
dot_config/private_fish/functions/gss.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gss
|
||||
command git status -sbu $argv
|
||||
end
|
3
dot_config/private_fish/functions/gsw.fish
Normal file
3
dot_config/private_fish/functions/gsw.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gsw
|
||||
command git switch $argv
|
||||
end
|
3
dot_config/private_fish/functions/gup.fish
Normal file
3
dot_config/private_fish/functions/gup.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gup
|
||||
command git pull $argv
|
||||
end
|
5
dot_config/private_fish/functions/gwta.fish
Normal file
5
dot_config/private_fish/functions/gwta.fish
Normal file
|
@ -0,0 +1,5 @@
|
|||
function gwta
|
||||
groot && cd ..
|
||||
command git worktree add $argv
|
||||
cd $argv
|
||||
end
|
3
dot_config/private_fish/functions/gwtp.fish
Normal file
3
dot_config/private_fish/functions/gwtp.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function gwtp
|
||||
command git worktree prune --verbose
|
||||
end
|
3
dot_config/private_fish/functions/k.fish
Normal file
3
dot_config/private_fish/functions/k.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function k
|
||||
command kubectl $argv
|
||||
end
|
3
dot_config/private_fish/functions/kc.fish
Normal file
3
dot_config/private_fish/functions/kc.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function kc
|
||||
command kubectl config $argv
|
||||
end
|
3
dot_config/private_fish/functions/kg.fish
Normal file
3
dot_config/private_fish/functions/kg.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function kg
|
||||
command kubectl get $argv
|
||||
end
|
3
dot_config/private_fish/functions/kshell.fish
Normal file
3
dot_config/private_fish/functions/kshell.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function kshell
|
||||
command kubectl exec -n "$1" --stdin --tty "$2" -- /bin/sh
|
||||
end
|
3
dot_config/private_fish/functions/ksw.fish
Normal file
3
dot_config/private_fish/functions/ksw.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function ksw
|
||||
command kubecm switch $argv
|
||||
end
|
3
dot_config/private_fish/functions/ll.fish
Normal file
3
dot_config/private_fish/functions/ll.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function ll
|
||||
ls -alg $argv
|
||||
end
|
3
dot_config/private_fish/functions/ls.fish
Normal file
3
dot_config/private_fish/functions/ls.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function ls
|
||||
command eza --group-directories-first --icons $argv
|
||||
end
|
3
dot_config/private_fish/functions/rgrep.fish
Normal file
3
dot_config/private_fish/functions/rgrep.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function rgrep
|
||||
grep --exclude-dir=.git -R $argv
|
||||
end
|
3
dot_config/private_fish/functions/s.fish
Normal file
3
dot_config/private_fish/functions/s.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function s
|
||||
termcompat ssh $argv
|
||||
end
|
3
dot_config/private_fish/functions/tailf.fish
Normal file
3
dot_config/private_fish/functions/tailf.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function tailf
|
||||
command less +F $argv
|
||||
end
|
15
dot_config/private_fish/functions/termcompat.fish
Normal file
15
dot_config/private_fish/functions/termcompat.fish
Normal file
|
@ -0,0 +1,15 @@
|
|||
function termcompat
|
||||
set -l term $TERM
|
||||
switch $term
|
||||
case 'alacritty*' 'kitty*' 'wezterm' 'xterm-*'
|
||||
set term xterm
|
||||
case 'rxvt-unicode-*'
|
||||
set term rxvt-unicode
|
||||
case 'tmux*'
|
||||
set term screen.xterm-new
|
||||
end
|
||||
begin
|
||||
set -lx TERM $term
|
||||
command $argv
|
||||
end
|
||||
end
|
3
dot_config/private_fish/functions/tig.fish
Normal file
3
dot_config/private_fish/functions/tig.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function tig
|
||||
termcompat tig $argv
|
||||
end
|
3
dot_config/private_fish/functions/tmux.fish
Normal file
3
dot_config/private_fish/functions/tmux.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function tmux
|
||||
command tmux -2 $argv
|
||||
end
|
3
dot_config/private_fish/functions/whence.fish
Normal file
3
dot_config/private_fish/functions/whence.fish
Normal file
|
@ -0,0 +1,3 @@
|
|||
function whence
|
||||
command -v $argv
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue