1
0
Fork 0
mirror of https://github.com/MillironX/dotfiles.git synced 2024-11-21 13:16:04 +00:00

refactor: Replace all shell command searching with Chezmoi searching

This commit is contained in:
Thomas A. Christensen II 2023-04-15 17:45:49 -05:00
parent f89211ef87
commit 433c576a44
Signed by: millironx
GPG key ID: 09335146883990B9

View file

@ -1,45 +1,38 @@
{{- if lookPath "pipx" }}
# Enable pipx completions
if [ $(command -v pipx) ]; then
eval "$(register-python-argcomplete pipx)"
fi
eval "$(register-python-argcomplete pipx)"
{{- end }}
{{- if lookPath "nvim" }}
# Preferred editor for local and remote sessions
if [ $(command -v nvim) ]; then
export EDITOR=nvim
elif [ $(command -v nano) ]; then
export EDITOR=nano
elif [ $(command -v vim) ]; then
export EDITOR=vim
elif [ $(command -v emacs) ]; then
export EDITOR='emacs -nw'
fi
export EDITOR=nvim
{{- end }}
if [ $(command -v kate) ]; then
export VISUAL=kate
elif [ $(command -v code) ]; then
export VISUAL=code
elif [ $(command -v emacs) ]; then
export VISUAL=emacs
fi
{{- if lookPath "kate" }}
export VISUAL=kate
{{- else if lookPath "codium" }}
export VISUAL=codium
{{- else if lookPath "code" }}
export VISUAL=code
{{- end }}
{{- if lookPath "most" }}
# Set a cool new pager with color support
if [ $(command -v most) ]; then
export PAGER=most
fi
export PAGER=most
{{- end }}
{{- if or (lookPath "bat") (lookPath "catbat") }}
# Replace cat with bat
if [ $(command -v bat) ]; then
export BAT_PAGER="less -SRF"
export MANPAGER="sh -c 'col -bx | bat -l man -p'"
export MANROFFOPT="-c"
fi
export BAT_PAGER="less -SRF"
export MANPAGER="sh -c 'col -bx | bat -l man -p'"
export MANROFFOPT="-c"
{{- end }}
# Add notification support for long-running processes
if [ $(command -v ntfy) ]; then
eval "$(ntfy shell-integration --longer-than 30)"
export AUTO_NTFY_DONE_IGNORE="vim nano emacs kate zshconfig screen tmux ssh top htop less more most nethogs 'singularity shell' julia man glances"
fi
{{- if lookPath "ntfy" }}
eval "$(ntfy shell-integration --longer-than 30)"
export AUTO_NTFY_DONE_IGNORE="vim nano emacs kate zshconfig screen tmux ssh top htop less more most nethogs 'singularity shell' julia man glances"
{{- end }}
# Set the Nextflow enviroment caches
export NXF_HOME="$HOME/.nextflow"