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

Re: Would this (o) be very difficult to add?



On Sep 27,  1:18pm, DervishD wrote:
} Subject: Re: Would this (o) be very difficult to add?
}
} [...] I cannot use this in a command: command $(print -lP...)
} results in 'command file name 1 file name 2', unquoted :(((

Since you're using "print -l" you have the filenames one per line.
Therefore, just quote the entire thing and split the output on newlines,
and all should be well:

    command ${(f)"$(print -lP ...)"}

Zsh is even clever enough to deal properly with nested double quotes
when ${...} or $(...) are involved.



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