diff options
| -rw-r--r-- | dotfiles/fish/conf.d/ai.fish | 4 | ||||
| -rw-r--r-- | dotfiles/fish/conf.d/editor.fish | 15 | ||||
| -rw-r--r-- | dotfiles/fish/conf.d/quickedit.fish | 9 |
3 files changed, 25 insertions, 3 deletions
diff --git a/dotfiles/fish/conf.d/ai.fish b/dotfiles/fish/conf.d/ai.fish index f1d11fc..5692643 100644 --- a/dotfiles/fish/conf.d/ai.fish +++ b/dotfiles/fish/conf.d/ai.fish @@ -5,7 +5,8 @@ abbr -a explain 'gh copilot explain' abbr -a aic 'aichat -e' # helix-gpt env vars used -set -gx COPILOT_MODEL gpt-4.1 # can be changed with aimodels function +# set -gx COPILOT_MODEL gpt-4.1 # can be changed with aimodels function +set -gx COPILOT_MODEL o3 # can be changed with aimodels function set -gx HANDLER copilot # TODO: also reconfigure aichat tool using this function @@ -15,6 +16,7 @@ function aimodels set -l COPILOT_CHAT_DIR "$NVIM_DIR/pack/copilotchat/start/CopilotChat.nvim/lua/CopilotChat" printf "gpt-4o +gpt-o3 gpt-4.1 claude-3.7-sonnet claude-3.7-sonnet-thought" >~/.aimodels diff --git a/dotfiles/fish/conf.d/editor.fish b/dotfiles/fish/conf.d/editor.fish index 8ce61db..bda4644 100644 --- a/dotfiles/fish/conf.d/editor.fish +++ b/dotfiles/fish/conf.d/editor.fish @@ -15,6 +15,19 @@ function editor::helix::open_with_lock rm $lock end +function editor::helix::open_with_lock::force + set -l file $argv[1] + set -l lock "$file.lock" + if test -f "$lock" + echo "File lock $lock exists! Force deleting it and terminating all $EDITOR instances?" + rm -f $lock + pkill -f $EDITOR + end + touch $lock + hx $file $argv[2..-1] + rm $lock +end + function editor::helix::edit::remote set -l local_path $argv[1] set -l remote_uri $argv[2] @@ -25,5 +38,7 @@ end abbr -a lhx 'editor::helix::open_with_lock' abbr -a hxl 'editor::helix::open_with_lock' +abbr -a hxlf 'editor::helix::open_with_lock::force' +abbr -a lhxf 'editor::helix::open_with_lock::force' abbr -a rhx 'editor::helix::edit::remote' abbr -a x hx diff --git a/dotfiles/fish/conf.d/quickedit.fish b/dotfiles/fish/conf.d/quickedit.fish index fd4dd63..234310f 100644 --- a/dotfiles/fish/conf.d/quickedit.fish +++ b/dotfiles/fish/conf.d/quickedit.fish @@ -68,17 +68,22 @@ function quickedit::direct end function quickedit::scratchpad - quickedit::direct ~/Notes/Scratchpad.md + quickedit::direct ~/Notes Scratchpad.md end function quickedit::quicknote - quickedit::direct ~/Notes/QuickNote.md + quickedit::direct ~/Notes QuickNote.md +end + +function quickedit::performance + quickedit::direct ~/Notes Performance.md end abbr -a e quickedit abbr -a scratch quickedit::scratchpad abbr -a S quickedit::scratchpad abbr -a quicknote quickedit::quicknote +abbr -a performance quickedit::performance abbr -a er "ranger $QUICKEDIT_DIR" abbr -a cdquickedit "cd $QUICKEDIT_DIR" abbr -a cdnotes 'cd ~/Notes' |
