From: Junio C Hamano <gitster@pobox.com>
To: "Issam Maghni via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, Issam Maghni <issam.e.maghni@mailbox.org>
Subject: Re: [PATCH] hook: test -a|o is not POSIX
Date: Fri, 07 Jan 2022 13:39:53 -0800 [thread overview]
Message-ID: <xmqqr19j6x92.fsf@gitster.g> (raw)
In-Reply-To: <pull.1172.git.git.1641528221530.gitgitgadget@gmail.com> (Issam Maghni via GitGitGadget's message of "Fri, 07 Jan 2022 04:03:41 +0000")
"Issam Maghni via GitGitGadget" <gitgitgadget@gmail.com> writes:
> From: "Issam E. Maghni" <issam.e.maghni@mailbox.org>
>
> I faced `test: too many arguments` when building using sbase [1]
Building "git" with sbase? It is curious how a loosely written
sample hook script can cause build failures on a platform with a
more strict userspace.
> This is due to a non-POSIX syntax `test ... -a ...` and `test … -o …`.
That's all correct. The formatting of the above line feels a bit
off, though.
>> The XSI extensions specifying the -a and -o binary primaries and the
>> '(' and ')' operators have been marked obsolescent.
> [2]
>
> [1] https://core.suckless.org/sbase/
> [2] https://pubs.opengroup.org/onlinepubs/9699919799/utilities/test.html
>
Perhaps...
The sample update script in the templates directory uses the
`-o` and `-a` binary primaries of the "test" command, which
are marked obsolescent in the recent versions of POSIX.
...would be sufficient, as 'sbase' would not be the only source of
the userspace whose 'test' lack the -o/-a primaries.
next prev parent reply other threads:[~2022-01-07 21:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-07 4:03 [PATCH] hook: test -a|o is not POSIX Issam Maghni via GitGitGadget
2022-01-07 21:39 ` Junio C Hamano [this message]
2022-01-07 22:31 ` Issam E. Maghni
2022-01-09 8:14 ` Bagas Sanjaya
2022-01-09 18:32 ` Junio C Hamano
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=xmqqr19j6x92.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=issam.e.maghni@mailbox.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.
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).