|
From: | Chet Ramey |
Subject: | Re: suggestion: shell option for echo to not interpret any argument as an option |
Date: | Wed, 26 Jul 2023 09:24:10 -0400 |
User-agent: | Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 |
On 7/26/23 8:42 AM, Zachary Santer wrote:
If POSIX mandates that '--' not be taken as the end of options, then the safe thing would be to simply not have echo take any options. Obviously, that would break backwards compatibility, so you'd want this to be optional behavior that the shell programmer can enable if desired.
set -o posix shopt -s xpg_echo -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
[Prev in Thread] | Current Thread | [Next in Thread] |