public inbox for goredo-devel@lists.stargrave.org
Atom feed
From: "ser.goredo=ser1.net via" <goredo-devel@lists.stargrave.org>
To: goredo-devel@lists.stargrave.org
Subject: [PATCH] REDO_SHELL sets which shell goredo uses
Date: Tue, 13 Oct 2026 09:02:21 -0700	[thread overview]
Message-ID: <20261013160546.1791075-1-ser.goredo@ser1.net> (raw)

Hi,

/bin/sh is not the same shell on all systems, and this can lead to non-trivial
`do` files failing on different machines. On Arch, /bin/sh is a symlink to bash;
on FuriOS (a mobile Debian distribution) it's symlinked to dash; on many
embedded systems, it's busybox (ash). dash and bash are not compatible,
especially in variable expansion, which can cause builds to fail across systems.

This patch adds a `REDO_SHELL` environment variable. If set, goredo will use
that executable as the shell it forks; otherwise, it will default to `/bin/sh`.
That is, this patch should be backwards compatible while allowing builds to
function without distribution-specific modification.

I didn't see anywhere in the repos where the environment variables are
documented, so there's no change that adds documentation. I think it's
documented only on the website?

 main.go | 3 +++
 run.go  | 4 +++-
 2 files changed, 6 insertions(+), 1 deletion(-)

--- SER

             reply	other threads:[~2026-10-13 16:24 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-13 16:02 ser.goredo=ser1.net via [this message]
2026-10-13 16:02 ` [PATCH] REDO_SHELL sets which shell goredo uses. Some OSes change which shell /bin/sh points to; on Arch, it's bash. On Debian (on some forks, at least), it's dash. These shells are incompatible, esp about topics like variable expansion. With REDO_SHELL, users can set which shell goredo forks and ensure builds run ser.goredo=ser1.net via
2026-10-14 14:05 ` [PATCH] REDO_SHELL sets which shell goredo uses Sergey Matveev (stargrave=stargrave.org) via
2026-10-14 16:08   ` "Sean E. Russell" (ser.goredo=ser1.net) via
2026-10-16  8:43     ` Sergey Matveev (stargrave=stargrave.org) via
2026-10-16  9:37     ` Authenticating the tarballs and website Sergey Matveev (stargrave=stargrave.org) via
2026-10-16 23:20       ` "Sean E. Russell" (ser=ser1.net) via
2026-10-17  7:02         ` Sergey Matveev (stargrave=stargrave.org) via