I have the following setup:
#!/bin/bash
function outer() {
function inner() {
...
}
... | xargs -L1 inner
}
So, I want to call inner for each of the lines that are generated in outer and call the function from an interactive shell. How would I do that?
I've tried exporting the inner function (from within outer) but that has no effect as I get 'no such file or directory'.
Note that inner calls xargs too, so for each output piped from outer to inner there will multiple executions (in case that makes a difference).