Open tmpm697 opened 7 months ago
See #1469 (also https://github.com/fmtlib/fmt/issues/3572)
Have to wait for next fmt release a new update to support %-H and %-I.
It's an upstream problem with https://github.com/fmtlib/fmt, if you wanna bug someone bug them.
@alttabber, I'm not trying to bug anybody, I'm just trying to get a clock display that 300 million Americans use daily. Also the UK, Ireland, Canada, Australia, Japan, India, Philippines, Mexico... I think even those old analog flip clocks with the digital chiclets in the '80s had a blank chiclet for 1-9 o'clock. I'm trying to get a clock display that I can get on every other clock applet and panel I've used. Nobody who uses a 12-hour clock displays it or says it as 02 o'clock.
I don't understand,is this not a regression...
https://github.com/Alexays/Waybar/issues/1469
So apparently this worked in waybar 9.12 or before. And entering date +%l:%M in a terminal displays the time properly...
❯ date +%l:%M
1:19
If this is a fmt issue and they've stalled on it... https://github.com/fmtlib/fmt/issues/2959
... why continue to use that library for waybar-clock? Like I said, xfce4-panel, GNOME, KDE, lxpanel, tint2, awesome panel, conky, etc... all can display a 12-hour clock without a leading zero.
Recommend collapsing this issue with https://github.com/Alexays/Waybar/issues/1469
libfmt has supported stripping the leading zero using -
(e.g. {:%-I:%M}
) since Feb of 2023:
commit 7718eeeacc98c2dfb6fe8714fb38ef31f2921ab9
Author: Shawn Zhong
Date: Wed Feb 8 11:22:58 2023 -0600
Implement glibc ext for sec, min, and hour (#3271)
But you'd want a new libfmt release before you'd want to use it (latest libfmt release 10.2.1 has this bug which is fixed but not released).
Once that's released, then waybar project would have to pick up that release.
@jayache80, thanks much for the update.
hi, it seems that i can't set to have hour without leading zero with clock module @alttabber @LukashonakV it will echo
clock: chromo format erorr: invalid specifier in chromo-specs
I have:
expect output:
Sun Mar 31 1:20 AM
--> no leading zero in hour1