Bugzilla – Bug 6884
Add a value to shortDateFormats
Last modified: 2009-11-26 23:41:40 UTC
I personally prefer the following shortDateFormat when viewing dates: q(%a %-m/%d) => q{WWW M/DD} Any chance of this being added to the default Utils/DateTime.pm? I currently have to put it in after every upgrade. :(
Hey, where do you get to see the short date at all? Can't test, as I don't find any...
The WeatherTime (http://code.google.com/p/weathertime/ ) plugin uses it by default.
Should this have been: q(%a %m/%d) => q{WWW M/DD} ^^^^^
No, the dash (-) makes it print only a single digit instead of zero padded two digits for Jan. - Sep.
Let's make this change in trunk for 7.0.1
Punting enhancements post 7.0.x series
change 19033 - please test and re-open if needed, thanks!
This bug has now been fixed in the 7.1 release version of SqueezeCenter! Please download the new version from http://www.slimdevices.com if you haven't already. If you are still experiencing this problem, feel free to reopen the bug with your new comments and we'll have another look.
Reduce number of active targets for SC
This change seems to have caused a bug: http://forums.slimdevices.com/showthread.php?t=70904 I can confirm the problem, and doing as Michael suggested seems to fix it. We are, however, in a double-digit month so haven't tested single digit yet. Cleary the regex isn't quite right.
Created attachment 6264 [details] proper strftime formatting (maybe) This seems to the be correct version for POSIX strftime in perl, at least on windows - so this site suggests: http://codingforums.com/showthread.php?t=73769
(In reply to comment #4) > No, the dash (-) makes it print only a single digit instead of zero padded two > digits for Jan. - Sep. Where did you find that information? Can't get this to work, neither using your format string nor kdf's alternate change (using #).
(In reply to comment #12) > (In reply to comment #4) > > No, the dash (-) makes it print only a single digit instead of zero padded two > > digits for Jan. - Sep. > > Where did you find that information? Can't get this to work, neither using your > format string nor kdf's alternate change (using #). From the man page on my Fedora box: Glibc Notes Glibc provides some extensions for conversion specifications. (These extensions are not specified in POSIX.1-2001, but a few other systems provide similar features.) Between the '%' character and the conversion specifier character, an optional flag and field width may be specified. (These precede the E or O modifiers, if present.) The following flag characters are permitted: _ (underscore) Pad a numeric result string with spaces. - (dash) Do not pad a numeric result string. 0 Pad a numeric result string with zeros even if the conversion specifier character uses space-padding by default. ^ Convert alphabetic characters in result string to upper case. # Swap the case of the result string. (This flag only works with certain conversion specifier characters, and of these, it is only really useful with %Z.) An optional decimal width specifier may follow the (possibly absent) flag. If the natural size of the field is smaller than this width, then the result string is padded (on the left) to the specified width.
> Glibc Notes > Glibc provides some extensions for conversion specifications. I've been testing on OSX - I doubt there are these Glibc extensions. Which means: if this is limited to systems using Glibc we'll have to live without the removal of the leading zero.
my patch, as noted ONLY works in windows. The fix that I did is only valid for windows version of strftime. The problem is that the strict ansi standard doesn't have the option for single-digit. Other platforms have it, but it's not standardised. I never found a true cross-platform option, and agree it's probably a lot of headache to try to add this small thing to the OS-dependant modules.
== Auto-comment from SVN commit #29494 to the slim repo by michael == == https://svn.slimdevices.com/slim?view=revision&revision=29494 == Fixed Bug: 6884 Description: fix the short date format. We're using our custom method stripping leading zeros (using |) to overcome platform limitations