Index | Thread | Search

From:
Manuel Giraud <manuel@ledu-giraud.fr>
Subject:
Re: Support for /usr/bin/env -S (kind of)
To:
Theo de Raadt <deraadt@openbsd.org>
Cc:
tech@openbsd.org
Date:
Fri, 18 Jul 2025 19:30:09 +0200

Download raw body.

Thread
  • Jeremie Courreges-Anglas:

    Support for /usr/bin/env -S (kind of)

  • Jeremie Courreges-Anglas <jca@wxcvbn.org> writes:
    
    [...]
    
    > Regardless of -S pros and cons, there is _no way_ you can change the
    > default behavior of env(1).  That would break many usage patterns just
    > for the sake of adding a workaround for scripts.
    >
    > In coreutils or FreeBSD env, -S takes a mandatory argument and only
    > that argument is split.  If we add -S, we should follow the same
    > logic.
    
    Alright.
    
    [...]
    
    > Personnally I don't feel strongly about it but I think there is value
    > in adding -S so that we don't have to write shell wrappers for
    > non-shell scripts written on other systems (or move those scripts to
    > genv(1)).
    
    As another data point, I tried to search for mentions of "env -S" in all
    the patch-* files of ports but couldn't find any.  Do you have examples
    where genv was used?
    -- 
    Manuel Giraud
    
    
  • Jeremie Courreges-Anglas:

    Support for /usr/bin/env -S (kind of)