From: Mikael Magnusson <mikachu@gmail.com>
To: "Jun T." <takimoto-j@kba.biglobe.ne.jp>
Cc: zsh workers <zsh-workers@zsh.org>
Subject: Re: PATCH: ztrftime: Pass everything unhandled to the system strftime()
Date: Fri, 10 Jul 2015 20:23:24 +0200 [thread overview]
Message-ID: <CAHYJk3RWU1sEDr7-FyVB4fPM28QELqtQgnMG-0WvnUge5SA4BQ@mail.gmail.com> (raw)
In-Reply-To: <8ECA2924-1605-4DC7-B6AA-557705C04E39@kba.biglobe.ne.jp>
On Fri, Jul 10, 2015 at 4:53 PM, Jun T. <takimoto-j@kba.biglobe.ne.jp> wrote:
> V09datetime fails on Mac OS X, because the OS does not
> support "%04y" nor "%Ey" but only skip_extensions is set.
>
> mac% strftime %04y 1
> 4y
> mac% LC_TIME=ja_JP.UTF-8 strftime %OS 1
> 01
>
> I think these two skip_* need be set independently.
>
>
> diff --git a/Test/V09datetime.ztst b/Test/V09datetime.ztst
> index a7ef983..475adde 100644
> --- a/Test/V09datetime.ztst
> +++ b/Test/V09datetime.ztst
> @@ -8,13 +8,8 @@
> unset LC_ALL
> LC_TIME=C
> TZ=UTC+0
> - if [[ "$(strftime %04y 1)" = "0070" ]]; then
> - [[ "$(LC_TIME=ja_JP.UTF-8 strftime %OS 1)" = 一 ]] || {
> - skip_japanese=1
> - }
> - else
> - skip_extensions=1
> - fi
> + [[ "$(strftime %04y 1)" = "0070" ]] || skip_extensions=1
> + [[ "$(LC_TIME=ja_JP.UTF-8 strftime %OS 1)" = 一 ]] || skip_japanese=1
>
> %test
Oops, yeah, I think I intended to check both of the parameters in the
second test case, then forgot. The idea is that only skip_japanese
can't be set, so I wrote the logic to enforce that. I'll commit this
as well to not print a misleading skip message if both are set.
@@ -34,7 +29,9 @@
>6_6_3_3
>000000
- if [[ $skip_japanese = 1 ]]; then
+ if [[ $skip_extensions = 1 ]]; then
+ ZTST_skip="strftime extensions not supported"
+ elif [[ $skip_japanese = 1 ]]; then
ZTST_skip="Japanese UTF-8 locale not supported"
else
(
--
Mikael Magnusson
next prev parent reply other threads:[~2015-07-10 18:23 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-07 23:15 PATCH: Make ztrftime pass more things to strftime Mikael Magnusson
2015-07-07 23:21 ` Mikael Magnusson
2015-07-08 10:53 ` Peter Stephenson
2015-07-09 5:16 ` Mikael Magnusson
2015-07-09 8:41 ` Peter Stephenson
2015-07-09 9:58 ` PATCH: ztrftime: Pass everything unhandled to the system strftime() Mikael Magnusson
2015-07-09 10:17 ` Peter Stephenson
2015-07-10 13:37 ` Peter Stephenson
2015-07-10 16:18 ` Skipping tests (was Re: PATCH: ztrftime: Pass everything ...) Bart Schaefer
2015-07-10 16:23 ` Peter Stephenson
2015-07-10 18:31 ` PATCH: ztrftime: Pass everything unhandled to the system strftime() Daniel Shahaf
2015-07-10 23:54 ` ZTST_skip (was Re: PATCH: ztrftime ...) Bart Schaefer
2015-07-09 15:52 ` PATCH: ztrftime: Pass everything unhandled to the system strftime() Jun T.
2015-07-10 14:53 ` Jun T.
2015-07-10 18:23 ` Mikael Magnusson [this message]
2015-07-27 11:56 ` Jun T.
2015-07-27 13:31 ` Mikael Magnusson
2015-07-27 16:50 ` Jun T.
2015-07-27 17:01 ` Jun T.
2015-09-01 13:53 ` Oliver Kiddle
2015-09-01 14:07 ` Peter Stephenson
2015-09-01 21:16 ` PATCH: Avoid gcc case syntax Mikael Magnusson
2015-07-08 14:03 ` PATCH: Make ztrftime pass more things to strftime Jun T.
2015-07-09 4:36 ` Mikael Magnusson
2015-07-08 10:39 ` Peter Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAHYJk3RWU1sEDr7-FyVB4fPM28QELqtQgnMG-0WvnUge5SA4BQ@mail.gmail.com \
--to=mikachu@gmail.com \
--cc=takimoto-j@kba.biglobe.ne.jp \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).