I have a pipeline like so:
tail -n0 -f "${my_input}" | ql_receiver_lock_holder | while read line; do echo "$line" >> "${my_output}"; # xxx: how can I programmatically close the pipeline at this juncture? done & disown; my question: is there a way to programmatically close the pipeline where it says xxx? I could probably just call exit 0; but I am wondering if there is a way to close the current pipeline somehow.
whileat all?ql_receiver_lock_holder | (read line; echo ...) & disownwould work just as well for that. Or do you want to end the loop? In which case a simplebreakwould do.breakout of the loop, but it is really difficult to understand what you want to archive.