-
Notifications
You must be signed in to change notification settings - Fork 41
Open
Labels
bugSomething is not workingSomething is not working
Description
~_ print ${.sh.version}
Version JM 93u+m/1.1.0-alpha+0f6866b6/MOD 2025-06-22
~_ printf '%(%Y)T\n' "Dec 20"
2026
~_ printf '%(%Y)T\n' "Jan 20"
2026
~_ printf '%(%Y)T\n' "Jan"
2025
~_ date -d "Dec 20" +%Y
2026
~_ date -d "Dec" +%Y
2025
~_ whence -a date
date is a shell builtin
date is /usr/bin/date
"Month day" input gives next year, not current. Same error also on AIX:
~> print -f '%(%Y)T\n' "Jan 20"
2026
~> print ${.sh.version}
Version JM 93u+m/1.1.0-alpha 2025-06-22
~> uname
AIX
Bug appears also in Version JM 93u+m/1.0.10 2024-08-01
Workaround is to use "first":
~_ print -f '%(%Y)T\n' "first Dec 20"
2025
~_ date -d "first Dec 20" +%Y
2025
Metadata
Metadata
Assignees
Labels
bugSomething is not workingSomething is not working