Re: protect backslash before space
Bart Schaefer <[email protected]> Wed, 1 Apr 2026 09:47:52 -0700
| Newsgroups | gmane.comp.shells.zsh.user |
|---|---|
| Message-ID | <CAH+w=7YiwaGUaC3WM1gVs-WgiA1nBX4AUPX6YchJepsOyqYP_g@mail.gmail.com> |
On Wed, Apr 1, 2026 at 9:08 AM Ray Andrews <[email protected]> wrote: > > I like my functions to be able to see their own tail. I have no idea what that means. > BTW, question: why does the script version above add the single quotes to indicate a single filename whereas the 'eval'ed version doesn't see the need? I'd vaguely expect the single quotes in both. I'm not entirely sure what this question means, either, but there's something strange about your examples, because you don't have noglob for the "." (dot) command so % . test junk* should be expanding and therefore passing two arguments to the "ls" at the end of the script. So there's something you're not showing us? Also, in either of your examples but using % . test junk* && test junk* for reference, the "alias test=..." created in the script will NOT be applied to the right-hand-side of the && when this is the first time this script is sourced in any given shell. Aliases have to be in place before the command line is accepted.