lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi,

Glenn Maynard wrote:
> On Tue, Feb 14, 2006 at 02:50:29PM +0800, Michael T. Richter wrote:
> > That, then, would fail under various UNIX environments.  Not a portable
> > solution.
> 
> Out of curiosity, where would it fail?  Is && a bashism?  It's much
> preferable to ";", since && will stop processing if the "cd" fails.

I also fail to see how && could be unportable. It has been there
since the first UNIX shells in existence.

Another evidence: GNU autoconf generates lots of 'cd foo && ...'
commands for Makefiles. And it's otherwise extremly conservative
when generating shell code (doesn't use functions, uses test
instead of '[').

IMHO it's safe to use this in the Lua Makefiles.

Bye,
     Mike