Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.misc > #85966

Re: On the sensibility of portable scripts

Path csiph.com!weretis.net!feeder8.news.weretis.net!news.tcpreset.net!newsgate.tebibyte.org!.POSTED.251.red-79-150-114.dynamicip.rima-tde.net!Telcontar.valinor!not-for-mail
From "Carlos E.R." <robin_listas@es.invalid>
Newsgroups comp.os.linux.misc
Subject Re: On the sensibility of portable scripts
Date Mon, 27 Apr 2026 13:07:27 +0200
Organization Tebibyte_Retro_Gaming
Message-ID <fks3cmxo2k.ln2@Telcontar.valinor> (permalink)
References <10s453n$5uph$1@dont-email.me> <8tjnbmxas1.ln2@Telcontar.valinor> <10sb89u$29ko5$4@dont-email.me> <p9lnbmx7q7.ln2@Telcontar.valinor> <n4v73kF414dU1@mid.individual.net> <34cqbmxlrh.ln2@Telcontar.valinor> <10se0t7$39rl2$2@dont-email.me> <a5eqbmx7t3.ln2@Telcontar.valinor> <10se5hv$39rl2$3@dont-email.me> <10smv4t$257nq$1@dont-email.me>
MIME-Version 1.0
Content-Type text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding 8bit
Injection-Info mailgate.tebibyte.org; posting-host="251.red-79-150-114.dynamicip.rima-tde.net:79.150.114.251"; logging-data="10110"; mail-complaints-to="abuse@tebibyte.org"
User-Agent Mozilla Thunderbird
Content-Language es-ES, en-CA
In-Reply-To <10smv4t$257nq$1@dont-email.me>
X-Leafnode-NNTP-Posting-Host 127.0.0.1
Xref csiph.com comp.os.linux.misc:85966

Show key headers only | View raw


On 2026-04-27 08:19, Lew Pitcher wrote:
> On Thu, 23 Apr 2026 22:13:19 +0000, Lew Pitcher wrote:
> 
>> On Thu, 23 Apr 2026 23:05:14 +0200, Carlos E.R. wrote:
>>
>> [snip]
>>> What is not right is declare in a script that it uses the common shell,
>>> and then have bashisms inside.
>>
>> Agreed. That's why my script does /not/ have bashisms inside.
>>
>> It uses the (POSIX shell) common subset that ash, bash, dash, ksh,
>> and zsh all support.
> 
> When writing scripts for distribution, it seems to me to be
> common sense to write those scripts in a manner such that they
> need as little customization as possible. You cannot know all
> the quirks of the environment in which it will run, but you can
> dictate some minimum requirements for the script.
> 
> If, for instance, you write a Perl or Python script for distribution,
> it must not, to be useful to the intended audience, assume much more
> than the common components of the selected language; a Python 3 script
> won't be much use on a system that only has Python 2 installed, unless
> it restricts itself to the subset of Python 3 syntax and features that
> are common with Python 2. Similarly, a bash script won't be of much use
> on a system that only has Korn shell installed, if it uses features
> only available in bash.

I disagree. A script published for bash, will be of use on any machine 
that has bash.

On your python script example you talked about versions of python, not 
about having a different interpreter like perl. If python is not 
installed, you see no problem demanding they install python.

Here, it is the same. You can not talk of having korn instead of bash, 
when the script clearly asks for bash.

Potatoes and lemons.

Now, if the scripts asks for "shell", that's a different thing.


...

> While some will argue against this, for their own reasons, I will
> continue to distribute POSIX shell compatible scripts.
> 
> For what it's worth.

That's fine, as long as the SHEBANG writes "sh".

-- 
Cheers, Carlos.
ES🇪🇸, EU🇪🇺;

Back to comp.os.linux.misc | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-20 03:04 +0000
  Re: CUPS print to FAX for Brother MFC printers 🇵🇱Jacek Marcin Jaworski🇵🇱 <jmj@energokod.gda.pl> - 2026-04-20 13:09 +0200
    Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-20 13:07 +0000
      Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-20 15:07 +0000
  CUPS print to FAX for Brother MFC printers, source code and manual (pt 1) Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-22 14:25 +0000
    Re: CUPS print to FAX for Brother MFC printers, source code and manual (pt 1) Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-22 14:27 +0000
      Re: CUPS print to FAX for Brother MFC printers, source code and manual (pt 1) Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-04-23 08:22 +0000
    Re: CUPS print to FAX for Brother MFC printers, source code and manual (pt 1) "J.O. Aho" <user@example.net> - 2026-04-23 10:09 +0200
  Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-22 21:24 +0200
    Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-22 19:41 +0000
      Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-22 21:48 +0200
        Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-23 01:14 +0000
        Re: CUPS print to FAX for Brother MFC printers Allodoxaphobia <trepidation@example.net> - 2026-04-23 18:35 +0000
          Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-23 20:05 +0000
            Re: CUPS print to FAX for Brother MFC printers Stéphane CARPENTIER <sc@fiat-linux.fr> - 2026-04-25 09:39 +0000
          Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-23 22:30 +0200
            Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-23 20:53 +0000
              Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-23 23:05 +0200
                Re: CUPS print to FAX for Brother MFC printers Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-23 22:13 +0000
                On the sensibility of portable scripts Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2026-04-27 06:19 +0000
                Re: On the sensibility of portable scripts Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-04-27 08:12 +0000
                Re: On the sensibility of portable scripts "Carlos E.R." <robin_listas@es.invalid> - 2026-04-27 12:42 +0200
                Re: On the sensibility of portable scripts Ian <gay@sfuu.ca> - 2026-04-27 09:43 -0700
                Re: On the sensibility of portable scripts rbowman <bowman@montana.com> - 2026-04-27 18:11 +0000
                Re: On the sensibility of portable scripts "Carlos E.R." <robin_listas@es.invalid> - 2026-04-27 23:24 +0200
                Re: On the sensibility of portable scripts Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-04-27 22:37 +0000
                Re: On the sensibility of portable scripts c186282 <c186282@nnada.net> - 2026-04-27 22:26 -0400
                Re: On the sensibility of portable scripts Marc Haber <mh+usenetspam2616@zugschl.us> - 2026-04-28 07:52 +0200
                Re: On the sensibility of portable scripts rbowman <bowman@montana.com> - 2026-04-27 18:08 +0000
                Re: On the sensibility of portable scripts "Carlos E.R." <robin_listas@es.invalid> - 2026-04-27 23:36 +0200
                Re: On the sensibility of portable scripts rbowman <bowman@montana.com> - 2026-04-27 18:06 +0000
                Re: On the sensibility of portable scripts "Carlos E.R." <robin_listas@es.invalid> - 2026-04-27 13:07 +0200
                Re: On the sensibility of portable scripts Richard Kettlewell <invalid@invalid.invalid> - 2026-04-27 21:00 +0100
              Re: CUPS print to FAX for Brother MFC printers Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-04-24 04:39 +0000
            Re: CUPS print to FAX for Brother MFC printers Stéphane CARPENTIER <sc@fiat-linux.fr> - 2026-04-25 09:41 +0000
              Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-25 13:57 +0200
          Re: CUPS print to FAX for Brother MFC printers Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-04-24 04:38 +0000
            Re: CUPS print to FAX for Brother MFC printers Richard Kettlewell <invalid@invalid.invalid> - 2026-04-24 08:45 +0100
              Re: CUPS print to FAX for Brother MFC printers Stéphane CARPENTIER <sc@fiat-linux.fr> - 2026-04-25 09:51 +0000
            Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-24 10:57 +0200
              Re: CUPS print to FAX for Brother MFC printers The Natural Philosopher <tnp@invalid.invalid> - 2026-04-24 10:31 +0100
                Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-24 11:43 +0200
                Re: CUPS print to FAX for Brother MFC printers The Natural Philosopher <tnp@invalid.invalid> - 2026-04-24 11:11 +0100
                Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-24 12:50 +0200
                Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-24 11:45 +0200
                Re: CUPS print to FAX for Brother MFC printers The Natural Philosopher <tnp@invalid.invalid> - 2026-04-24 11:11 +0100
                Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-24 12:51 +0200
                Re: CUPS print to FAX for Brother MFC printers The Natural Philosopher <tnp@invalid.invalid> - 2026-04-24 13:42 +0100
                Re: CUPS print to FAX for Brother MFC printers Bobbie Sellers <bliss-sf4ever@dslextreme.com> - 2026-04-24 18:53 -0700
          Re: CUPS print to FAX for Brother MFC printers jayjwa <jayjwa@atr2.ath.cx.invalid> - 2026-04-25 12:01 -0400
            Re: CUPS print to FAX for Brother MFC printers "Carlos E.R." <robin_listas@es.invalid> - 2026-04-25 22:05 +0200
            Re: CUPS print to FAX for Brother MFC printers Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-04-26 01:18 +0000
              Re: CUPS print to FAX for Brother MFC printers Marc Haber <mh+usenetspam2616@zugschl.us> - 2026-04-26 09:46 +0200
              Re: CUPS print to FAX for Brother MFC printers jayjwa <jayjwa@atr2.ath.cx.invalid> - 2026-04-26 11:31 -0400
                Re: CUPS print to FAX for Brother MFC printers John Bokma <contact@johnbokma.com> - 2026-04-26 19:31 +0200
                Re: CUPS print to FAX for Brother MFC printers The Natural Philosopher <tnp@invalid.invalid> - 2026-04-26 20:18 +0100
                Re: CUPS print to FAX for Brother MFC printers Lars Poulsen <lars@beagle-ears.com> - 2026-04-27 15:56 -0700

csiph-web