Update conditional checks and add yadm pre_commit hook

This commit is contained in:
Tobias Reisinger 2023-10-20 14:57:50 +02:00
parent d3ba8c473d
commit 1251bb4eab
Signed by: serguzim
GPG key ID: 13AD60C237A28DFE
5 changed files with 45 additions and 9 deletions
.config

View file

@ -71,17 +71,17 @@ alias xdebug='XDEBUG_CONFIG="remote_host=127.0.0.1 remote_port=9003"'
### conditionals
[ -x "$(command -v bat)" ] && alias cat='bat -pp'
test -x "$(command -v bat)" && alias cat='bat -pp'
[ -x "$(command -v eza)" ] && alias ls='eza -lhF --git --icons --color=always --color-scale --time-style=long-iso --group-directories-first'
test -x "$(command -v eza)" && alias ls='eza -lhF --git --icons --color=always --color-scale --time-style=long-iso --group-directories-first'
[ -x "$(command -v moar)" ] && alias less='moar'
test -x "$(command -v moar)" && alias less='moar'
[ -x "$(command -v nvim)" ] && alias vim='nvim'
test -x "$(command -v nvim)" && alias vim='nvim'
[ -x "$(command -v rmtrash)" ] && alias rm='rmtrash -I --one-file-system'
[ -x "$(command -v rmdirtrash)" ] && alias rmdir='rmdirtrash'
test -x "$(command -v rmtrash)" && alias rm='rmtrash -I --one-file-system'
test -x "$(command -v rmdirtrash)" && alias rmdir='rmdirtrash'
[ ! -x "$(command -v yadm)" ] && alias yadm='git --git-dir="$HOME/.local/share/yadm/repo.git"'
test ! -x "$(command -v yadm)" && alias yadm='git --git-dir="$HOME/.local/share/yadm/repo.git"'
[ -f "$HOME/.config/aliasrc.local" ] && . "$HOME/.config/aliasrc.local"
test -x "$HOME/.config/aliasrc.local" && . "$HOME/.config/aliasrc.local"