[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] add semicolon if last word in command group ends in &
From: |
Chet Ramey |
Subject: |
Re: [PATCH] add semicolon if last word in command group ends in & |
Date: |
Fri, 16 Jun 2023 14:58:45 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 |
On 6/10/23 10:41 PM, Martin D Kealey wrote:
On Sun, 11 Jun 2023, 09:31 Grisha Levit, <grishalevit@gmail.com> wrote:
The command printing code can fail to add a required semicolon when the
last word in the command ends with `&'
This could be obviated by unconditionally outputting a newline instead of a
semicolon.
There's some merit to this; the existing group command printing code
already prints group commands on multiple lines if within a shell function.
I acknowledge that this style isn't to everyone's taste, but to me it feels
more "natural" to the Shell, rather than pretending that one is writing in
some other language; I detest style guides that insist on obscuring ";then"
on the end of a long line.
Everyone has a preference.
--
``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/