34 lines
1.1 KiB
Fish
34 lines
1.1 KiB
Fish
|
|
if status is-interactive
|
||
|
|
# Commands to run in interactive sessions can go here
|
||
|
|
# /bin/cat /home/$USER/.cache/wal/sequences
|
||
|
|
if test $fish_pid = (pgrep fish | sed -n '2p')
|
||
|
|
if test -e /tmp/small.jsonc
|
||
|
|
fastfetch -c /tmp/small.jsonc
|
||
|
|
else
|
||
|
|
fastfetch -c $XDG_CONFIG_HOME/fastfetch/small.jsonc
|
||
|
|
end
|
||
|
|
motd
|
||
|
|
end
|
||
|
|
function y
|
||
|
|
set tmp (mktemp -t "yazi-cwd.XXXXXX")
|
||
|
|
yazi $argv --cwd-file="$tmp"
|
||
|
|
if read -z cwd <"$tmp"; and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
|
||
|
|
builtin cd -- "$cwd"
|
||
|
|
end
|
||
|
|
rm -f -- "$tmp"
|
||
|
|
end
|
||
|
|
source /usr/share/wikiman/widgets/widget.fish
|
||
|
|
set --erase FZF_DEFAULT_OPTS
|
||
|
|
set -Ux FZF_DEFAULT_OPTS (cat $XDG_CACHE_HOME/wal/colors-fzf) --preview \'fzfp {}\' --bind \'enter:execute\(open \{\}\)\'
|
||
|
|
fzf_key_bindings
|
||
|
|
abbr -a !! --position anywhere --function last_history_item
|
||
|
|
abbr -a dotdot --regex '^\.\.+$' --function multicd
|
||
|
|
abbr -a cr cargo run
|
||
|
|
end
|
||
|
|
|
||
|
|
set -Ux FZF_DEFAULT_COMMAND 'fd --type f --strip-cwd-prefix --follow'
|
||
|
|
|
||
|
|
# fish_add_path /home/candle/.spicetify
|
||
|
|
|
||
|
|
zoxide init --cmd cd fish | source
|