dotfiles/.config/fish/functions/date_format.fish

7 lines
203 B
Fish

function date_format --description 'Format date for task'
if not date -d "$argv" +%Y-%m-%dT%H:%M &>/dev/null
date +%Y-%m-%dT%H:%M
else
date -d "$argv" +%Y-%m-%dT%H:%M
end
end