From: Grant Edwards <grant.b.edwards@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: [gentoo-user] Re: Writing more complicated scripts than I'm used too.
Date: Wed, 2 Jul 2025 18:26:11 -0000 (UTC) [thread overview]
Message-ID: <1043tk3$15fd$1@ciao.gmane.io> (raw)
In-Reply-To: e3f3f800-8174-4e1f-99af-33df70a672b0@gentoo.org
On 2025-07-02, Eli Schwartz <eschwartz@gentoo.org> wrote:
> Yes, in general [[ is better than [
>
> The practical difference is that it is parsed as a keyword, not as an
> ordinary command, hence it knows what is inside of it without whitespace
> handling. i.e.
>> [And it's even support
>> by busybox's ash shell.]
>
>
>
> Beware that busybox ash supports [[ "partially".
>
> From the busybox source code comments:
Ah, thanks for pointing that out. I apparently haven't run into those
incompibilities yet, but I'll have to keep them in mind. When writing
scripts of an embedded system, I tend to write/test scripts in bash,
then test them with ash on the target system. What I _should_ do is
install busybox on my development host and do the development using
busybox ash as well.
--
Grant
next prev parent reply other threads:[~2025-07-02 18:27 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-14 3:44 [gentoo-user] Writing more complicated scripts than I'm used too Dale
2025-06-14 8:42 ` Sascha Spreitzer
2025-06-14 17:18 ` Bryan Gardiner
2025-06-15 20:53 ` Frank Steinmetzger
2025-07-01 23:50 ` Dale
2025-07-02 0:26 ` Frank Steinmetzger
2025-07-02 0:47 ` Dale
2025-07-02 1:10 ` Eli Schwartz
2025-07-02 2:41 ` [gentoo-user] " Grant Edwards
2025-07-02 3:18 ` Eli Schwartz
2025-07-02 4:22 ` Dale
2025-07-02 5:21 ` Alexis
2025-07-02 18:27 ` Grant Edwards
2025-07-03 18:47 ` Dale
2025-07-03 21:56 ` Arve Barsnes
2025-07-04 0:19 ` Dale
2025-07-02 18:26 ` Grant Edwards [this message]
2025-07-02 1:10 ` [gentoo-user] " Eli Schwartz
2025-07-02 1:33 ` Dale
2025-07-02 2:04 ` Javier Martinez
2025-07-02 2:31 ` Dale
2025-07-02 2:44 ` Javier Juan Martinez Cabezon
2025-07-02 4:07 ` Dale
2025-09-18 15:58 ` Dale
2025-09-18 17:37 ` Michael
2025-09-18 21:51 ` Dale
2025-09-19 8:33 ` Michael
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='1043tk3$15fd$1@ciao.gmane.io' \
--to=grant.b.edwards@gmail.com \
--cc=gentoo-user@lists.gentoo.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