dateutils
dateutils copied to clipboard
datetest appears to accept nonsense when using --isvalid
datetest --isvalid -i %FT%T -i %F -- 2022-02-27 # Okay
datetest --isvalid -i %FT%T -i %F -- 2022-02-27T # Should fail
datetest --isvalid -i %FT%T -i %F -- 2022-02-27T9999:8888:7777 # Should definately fail
It seems that if 2022-02-27
is matched, anything after it is also accepted.
Is there a proper way to have datetest
check the validity of an input based on multiple formats (i.e. a subset of ISO8601 or RFC3339)?
Hi, thanks for the report, good catch. Fix is in 06198a860.