Re: non-blocking stdin from bash
On Mon, 2018-08-13 at 08:59 -0400, Greg Wooledge wrote:
> On Sat, Aug 11, 2018 at 06:08:34PM -0400, Jim Popovitch wrote:
> > What's the best way to grab anything that's in stdin into a
> > variable inside a bash script, but won't block if stdin is null?
> On Sun, Aug 12, 2018 at 01:57:09PM -0400, Jim Popovitch wrote:
> > Interesting. I'm using it via a cron script like so:
> > * * * * * grep "unusual" /opt/logs/* | /opt/notify.sh `hostname`;
> On Sun, Aug 12, 2018 at 06:45:23PM -0400, Jim Popovitch wrote:
> > That was just an example of what I'm doing. In reality logtail's
> > in there, but it made the example line too long.
Come on, that's not warranted.... or you just like posting links to you
own site. smh.