Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Using file lines as "input files"
- X-seq: zsh-users 27876
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: dominik.vogt@xxxxxx, Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: Using file lines as "input files"
- Date: Fri, 8 Jul 2022 23:58:58 +0200
- Archived-at: <https://zsh.org/users/27876>
- In-reply-to: <Ysiacl2I2eYF+uY4@gmx.de>
- List-id: <zsh-users.zsh.org>
- References: <Ysiacl2I2eYF+uY4@gmx.de>
On 7/8/22, Dominik Vogt <dominik.vogt@xxxxxx> wrote:
> So, would it be possible to pass each line in "$INFILE" as a file
> argument to "cksum", i.e.
>
> $ chksum Fline1 Fline2 Fline3 ... Fline265000
Assuming that the above command works, you should be able to do
% cksum ${(f)"$(<$INFILE)"}
Depending on your kernel this may be too long of a command line, you
can use zargs (or xargs) to work around that if needed, or if you're
on Linux you may be able to increase your stack size with ulimit -s,
eg
% ulimit -s 132768
(my default is 8192 which is not enough for the given example)
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author