aboutsummaryrefslogblamecommitdiff
path: root/sh/profile.d/remind.sh
blob: 3ef0f35363274ae89c2da84c6361bf374d2648ba (plain) (tree)


















                                                           
# Only if shell is interactive
case $- in
    *i*) ;;
    *) return ;;
esac

# Only if not in a tmux window
[ -z "$TMUX" ] || return

# Only if ~/.welcome/remind exists and ~/.hushlogin doesn't
[ -e "$HOME"/.welcome/remind ] || return
! [ -e "$HOME"/.hushlogin ] || return

# Only if rem(1) available
command -v rem >/dev/null 2>&1 || return

# Print reminders with asterisks
rem -hq | sed 's/^/* /'
printf '\n'