#!/usr/bin/env bash function stdout() { # 2023-03-08 at 2.06.15 AM date +"%Y-%m-%d at %H.%M.%S %p" } function pipeout() { # tr '[:space:]' '\t' | gsed 's/\s*$//g' } if [ -t 1 ]; then stdout else stdout | pipeout fi