* SImple way to execute command on list of files?
@ 2019-04-14 8:46 Dominik Vogt
2019-04-17 2:09 ` Anthony Heading
0 siblings, 1 reply; 2+ messages in thread
From: Dominik Vogt @ 2019-04-14 8:46 UTC (permalink / raw)
To: Zsh Users
Other than writing an alias or a function, is there a simple way
to call commands that take only one file argument multiple times?
In other words
$ xpdf *.pdf
$ ps2pdf a.ps b.ps c.ps
should be executed (semantically) as
$ for F in *.pdf; do xpdf "$F"; done
$ ps2pdf a.ps; ps2pdf b.ps; ps2pdf c.ps
I'm looking for a kind of extension for the command syntax. Of
course I could write a function with that syntax for each command,
but is there a more general way where you can define a list of
commands to treat differently, say
annoying_commands xpdf ps2pdf gv
Ciao
Dominik ^_^ ^_^
--
Dominik Vogt
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-04-17 2:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-14 8:46 SImple way to execute command on list of files? Dominik Vogt
2019-04-17 2:09 ` Anthony Heading
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).