Add mails from cron to prompt
This commit is contained in:
parent
d86ef1c7b9
commit
2f45a347ac
|
@ -13,6 +13,8 @@ alias :q="exit"
|
|||
alias rget="rsync -rP --append-verify --inplace"
|
||||
alias 7zu="7z a -t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on"
|
||||
|
||||
alias cronmail="mutt -f $MAIL"
|
||||
|
||||
if ! command -v fd >/dev/null; then
|
||||
fd() {
|
||||
if [[ "$1" =~ "-*" ]]; then
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# autoload completions
|
||||
fpath=( "${ZDOTDIR:+$ZDOTDIR/compdef}" "/etc/zsh/compdef" $fpath )
|
||||
fpath=("$XDG_DATA_HOME/scalacli/completions/zsh" $fpath)
|
||||
|
||||
[[ -n $(echo /etc/zsh/compdef/*(N:t)) ]] && autoload -U /etc/zsh/compdef/*(N:t)
|
||||
[[ -n $(echo $ZDOTDIR/compdef/*(N:t)) ]] && autoload -U $ZDOTDIR/compdef/*(N:t)
|
||||
|
|
12
zshrc
12
zshrc
|
@ -102,7 +102,11 @@ if [[ -e $HOME/.calendars ]]; then
|
|||
}
|
||||
__chromaz_extra_left+=_prompt_todos
|
||||
fi
|
||||
# >>> scala-cli completions >>>
|
||||
fpath=("/home/crater2150/.local/share/scalacli/completions/zsh" $fpath)
|
||||
compinit
|
||||
# <<< scala-cli completions <<<
|
||||
|
||||
if exists mail; then
|
||||
_prompt_cron_mails() {
|
||||
local newmails=$(mail -Hf $MAIL | grep -c '^.N')
|
||||
[[ $newmails -gt 0 ]] && echo "Cron Notifications: $newmails"
|
||||
}
|
||||
__chromaz_extra_left+=_prompt_cron_mails
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue