pipe-tools
Software
www.skarnet.org
The npt-or program
npt-or listens to a fifodir until it has been notified with
one event in a given set. It's a simple interface to the
nptrigger_wfo()
library call.
Interface
npt-or fifodir event1 event2 ...
npt-or blocks until fifodir has been notified with
one of the eventi. Then it writes the event
on its stdout, without a trailing newline, and exits 0.
If one of the events is composed of only null characters,
it acts as a wildcard: any event will match it.
You should use npt-or with
maximumtime to ensure that it does not
block forever.
Notes
The goal of npt-or is to implement portable checkpoint
disjunction.