-
-
Notifications
You must be signed in to change notification settings - Fork 313
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ExecForEach
#22
Comments
Would like to help out on this. |
Great! Thanks @gagneet. One thing you could do to get the ball rolling is to write a short |
I am thinking the func (p *Pipe) Xargs(cmd ...string) *Pipe {
// do something with the output of the previous command
} or func (p *Pipe) Xargs(cmd string) *Pipe {
// do something with the output of the previous command
} This would take a Pipe and use its output to perform more commands. I am still thinking through, as I look to find more scenarios that the |
@bitfield what do you think? |
I think using script.ListFiles("*.php").ExecForEach("php {{ . }}").Stdout() |
Equivalent to shell
xargs
. For example, this use case: https://gist.github.com/Skraelingjar/9aabc58aa26f5b814411e69d67b342feThe text was updated successfully, but these errors were encountered: