#!/usr/bin/env bash set -euo pipefail if [ "${1-}" == "--help" ] || [ "${1-}" == "-h" ]; then echo "usage: ynote [notename]" echo " create a yearly note in \$NOTESDIR/year" echo " default \$NOTESDIR is ~/Notes" echo " yours is ${NOTESDIR-$HOME/Notes}" echo " default notename is 'yearly'" echo " multi word notenames accepted without quotes." else NOTEBIN="$( dirname -- "$( readlink -f -- "$0"; )"; )" $NOTEBIN/arbnote yearly "$*" fi