[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ignore errors on specific command
From: |
Payal |
Subject: |
Re: ignore errors on specific command |
Date: |
Wed, 31 Mar 2010 04:03:39 -0700 |
User-agent: |
Mutt/1.5.18 (2008-05-17) |
On Wed, Mar 31, 2010 at 11:16:53AM +0200, Stephan Beal wrote:
> On Wed, Mar 31, 2010 at 10:27 AM, Payal <address@hidden>wrote:
>
> > all:
> > cmd1 ; cmd2; cmd3
> >
> > How to ignore errors from cmd2 only? Putting -cmd2 will not work here.
> >
On the same line how do I turn OFF echoing of cmd2 and cmd3 only.
> The return value of cmd2 WILL be ignored here. cmd2 might still generate
> error messages but it will not cause make to fail because make is only
> interested in the last return code of each shell command (in this case, that
> of cmd3).
>
> That said, you can explicitly force the return code to be 0 with:
>
> all:
> cmd1 ; cmd2 || true ; cmd3
So, to ignore errors from cmd3, I have to do,
cmd1 ; cmd2 ; cmd3 || true
right?
With warm regards,
-Payal
--