Skip to main content
3 events
when toggle format what by license comment
May 31, 2023 at 10:29 comment added Neinstein @aviro That makes even more sense. After the job is killed, there are no new lines, so tail gets nothing. Of course it didn't stop. Re: sigint, it actually worked, but you're right, there's no need for it. It was a leftover from another version where the loop was running in the background and tail in the main process.
May 31, 2023 at 10:22 comment added aviro It's not only the SIGPIPE; The tail command will only get a SIGPIPE if it tries to write something to the pipe. If there are no new lines in the file it follows, it will not try to write anything and won't receive the signal. Also, I'm not sure the SIGINT signal you're sending (-2) would work, since bash disables SIGINT on background processes
May 31, 2023 at 10:14 history answered Neinstein CC BY-SA 4.0