On Tue, Dec 9, 2008 at 5:19 PM, Jan Minář <[EMAIL PROTECTED]> wrote: > Hi. > > date(1) command parses "next $day_of_week_today" (where > $day_of_week_today is today's day name) incorrectly: > > $ date > Tue Dec 9 17:16:50 GMT 2008 > $ date -d "next `date +%A`" > Tue Dec 9 00:00:00 GMT 2008 > > It should print the next Tuesday's date, i.e. today + 7 days.
The date parser does not support as input weekday names in arbitrary languages; see the documentation for the date command. Fortunately, the problem is simple to work around, by overriding the locale selection for the inner date command:- $ date -d "next `LC_ALL=C date +%A`" mercredi 10 décembre 2008, 00:00:00 (UTC+0000) James.
_______________________________________________ Bug-coreutils mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-coreutils
