Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: why not promote the plague ? (brace|rc|alternative|modern) syntax



On Thu, Dec 12, 2024, at 10:16 AM, Marc Chantreux wrote:
> the thing that
> unfairly keep people away from zsh around me is the nested, long
> parameter expansions (and I have to admit sometimes I'm still confused
> about it). I encourage people practice and to get used to it, promise
> assistance but still, they don't want to use it.

I don't blame people for avoiding such expansions.  I sometimes
find them borderline illegible, too.  (Granted, zsh doesn't *force*
anyone to write such expansions, but I guess reading others' can
be daunting.)

>> addition to bugs and fringe behavioral differences from the normal syntax i see
>> little gain in doing so apart from some people find it aesthetically pleasing.
>
> This isn't aesthetical: it's much faster to type, edit and read
> especially if you use the zle vi mode (or if you fc in vim) which 
> became very advanced.

I don't begrudge anyone their productivity shortcuts, but IMO there
are too many asterisks and pitfalls to recommend the short forms.
(Shell scripting is already a minefield of asterisks and pitfalls
and other mixed metaphors; new ones should be introduced with care.)

-- 
vq




Messages sorted by: Reverse Date, Date, Thread, Author