Re: sort: new feature: use environment variable to set buffer size (original) (raw)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
From: | Jim Meyering |
---|---|
Subject: | Re: sort: new feature: use environment variable to set buffer size |
Date: | Thu, 30 Aug 2012 11:02:54 +0200 |
Pádraig Brady wrote:
Thanks for the detailed rationale, however the existing env variables are significant to more utils than sort(1). I.E. they're generally system level settings, rather than command level. Also sort -S is very portable, even though not standardised. solaris' sort(1) has -S and GNU sort is used on most other platforms, which has -S available since TEXTUTILS-2010-58-gbf86c62
Note also this thread on the selection of a default buffer size for pipes: http://thread.gmane.org/gmane.comp.gnu.coreutils.general/878/focus=887
So currently I'd be 70:30 against adding such a variable.
Thanks for replying, Pádraig. Those are good points. Another is that we have a strong aversion to adding support for new environment variables in coreutils programs because it makes formerly-robust usage prone to malfunction or abuse.
Imagine a script that worked fine before, but when someone ends up running sort with some unusual or extreme envvar setting that now makes that shell script's use of sort fail.
With a new envvar as proposed, every sort-using script would have to be retrofitted with code to keep an erroneous or malicious envvar setting from impacting sort.
Just say "No!" to new envvars ;-)
- sort: new feature: use environment variable to set buffer size, Assaf Gordon, 2012/08/29
- Re: sort: new feature: use environment variable to set buffer size, Pádraig Brady, 2012/08/29
* Re: sort: new feature: use environment variable to set buffer size,Jim Meyering <=
* Re: sort: new feature: use environment variable to set buffer size, Assaf Gordon, 2012/08/30
- Re: sort: new feature: use environment variable to set buffer size, Pádraig Brady, 2012/08/29
- Prev by Date:Re: [PATCH 00/22] Towards a non-recursive build system for coreutils?
- Next by Date:Re: [PATCH] tests: misc/sort-exit-early: do not run as root.
- Previous by thread:Re: sort: new feature: use environment variable to set buffer size
- Next by thread:Re: sort: new feature: use environment variable to set buffer size
- Index(es):