X-Git-Url: https://git.madduck.net/etc/mutt.git/blobdiff_plain/e877e8ebd7d67d025a154a47daded892710e299c..d60226ed4be8d76d12ee1db8f46ee49de9c3a567:/.mutt/get-timestamp?ds=sidebyside diff --git a/.mutt/get-timestamp b/.mutt/get-timestamp index 919936a..f165be6 100755 --- a/.mutt/get-timestamp +++ b/.mutt/get-timestamp @@ -19,14 +19,15 @@ case "$timespec" in echo "E: empty timespec" >&2 exit 1 ;; - @[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]|*' '*) + @[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]) + date="$timespec";; + [0-9][0-9][0-9][0-9][-.][0-9][0-9][-.][0-9][0-9]) date="$timespec";; *[0-9]y) date="now + ${timespec%y} years 00:00";; *[0-9]m) date="now + ${timespec%m} months 00:00";; *[0-9]w) date="now + ${timespec%w} weeks 00:00";; *[0-9]d|*[0-9]) date="now + ${timespec%d} days 00:00";; *[0-9]h) date="now + ${timespec%h} hours";; - *' '*) date="$args";; *) date="$timespec";; esac