mirror of
https://github.com/kristoferssolo/solorice.git
synced 2026-03-18 08:09:40 +00:00
Update 2026-03-17
This commit is contained in:
13
config/fish/conf.d/auto-venv.fish
Normal file
13
config/fish/conf.d/auto-venv.fish
Normal file
@@ -0,0 +1,13 @@
|
||||
function __auto_vent --on-variable PWD
|
||||
if test -f "$PWD/.venv/bin/activate.fish"
|
||||
source "$PWD/.venv/bin/activate.fish"
|
||||
return
|
||||
end
|
||||
|
||||
if set -q VIRTUAL_ENV
|
||||
set -l project_dir (path dirname $VIRTUAL_ENV)
|
||||
if not string match -q "$project_dir" "$PWD" and not string match -q "$project_dir/*" "$PWD"
|
||||
deactivate 2>/dev/null
|
||||
end
|
||||
end
|
||||
end
|
||||
5
config/fish/conf.d/bang.fish
Normal file
5
config/fish/conf.d/bang.fish
Normal file
@@ -0,0 +1,5 @@
|
||||
function __last_history_item
|
||||
echo $history[1]
|
||||
end
|
||||
|
||||
abbr --add !! --position anywhere --function __last_history_item
|
||||
Reference in New Issue
Block a user