Example:
If I do
%a %B %y %m %M %S
It will display
Thu March 16 03 52 33
It displays the time in 24 hour format. I want the 12 hour format instead.
Are there any options I can do to make it display this?
Thu 3/16 1:53PM
Well, that depends on which taskbar you're using. There's dozens of them.
However, your example seems to be using the strftime syntax, in which...
%a
,%m
,%-m
,%d
,%I
,%-d
or %-I
,%m
,%p
.Note that %-x
is specific to Linux (glibc), it won't work on other operating systems (even though e.g. BSDs also use strftime).
Also, while in your case this is probably already configured right, for completeness I'll mention that that %p
seems to only work if the system locale is set to one that uses a 12-hour clock. (You don't have to change the main LANG
setting, just LC_TIME=en_US.UTF-8
is enough. For example, I want the opposite, so I set LC_TIME=en_DK.UTF-8
to get a 24-hour clock while keeping the rest as en_US.UTF-8
.)
I can't be entirely certain it's the same, but these look like strftime
variables. Try the following:
%a %m/%y %k:%M%P
or this which may remove the month padding: (Thanks @grawity)
%a %-m/%y %k:%M%P
Further information: strftime glibc - strftime unix
%-m
for no padding. See the glibc strftime manpage. You'll probably want the same for days and hours.
Mar 18, 2016 at 6:05