2024-01-17 10:24:24 +09:00
|
|
|
set -x 0 fish
|
|
|
|
|
2024-01-17 18:00:07 +09:00
|
|
|
{{ if ne .chezmoi.username "root" -}}
|
2024-01-17 10:24:24 +09:00
|
|
|
source $HOME/.config/fish/env.fish
|
2024-01-17 17:44:13 +09:00
|
|
|
{{- end }}
|
2024-01-17 10:24:24 +09:00
|
|
|
|
|
|
|
# ONLY for interactive shell
|
|
|
|
if status --is-interactive
|
2024-01-17 18:00:07 +09:00
|
|
|
{{ if ne .chezmoi.username "root" -}}
|
2024-01-17 10:24:24 +09:00
|
|
|
source $HOME/.config/fish/abbreviations.fish
|
2024-01-17 17:44:13 +09:00
|
|
|
{{- end }}
|
2024-01-17 10:24:24 +09:00
|
|
|
set -q fish_private_mode && set -x FISH_IS_IN_PRIVATE 1
|
|
|
|
command -v zoxide > /dev/null && zoxide init fish | source
|
|
|
|
command -v starship > /dev/null && starship init fish | source
|
|
|
|
end
|
|
|
|
|
|
|
|
{{- if (and (eq .chezmoi.os "linux") (eq .hosttype "desktop" "laptop")) }}
|
|
|
|
if status --is-login
|
|
|
|
if test -z "$DISPLAY" -a "$XDG_VTNR" = 1
|
|
|
|
exec startx $HOME/.config/X11/xinitrc -- -keeptty -ardelay 200 -arinterval 60
|
|
|
|
end
|
|
|
|
end
|
|
|
|
{{- end }}
|