delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2008/06/06/10:47:18

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Fri, 6 Jun 2008 10:46:43 -0400
From: Christopher Faylor <cgf-use-the-mailinglist-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: Patch to allow Cron to use non-POSIX shells like Powershell.exe and CMD.exe
Message-ID: <20080606144643.GA31485@ednor.casa.cgf.cx>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <2abc9c2d0806040808s2178885ak5dcf7cd528ea685a AT mail DOT gmail DOT com> <2abc9c2d0806040948l2f6dc1cbjd99bbdaea65cf181 AT mail DOT gmail DOT com> <006701c8c756$1b923260$d50410ac AT wirelessworld DOT airvananet DOT com> <2abc9c2d0806051528w6aa5c8f5g6bf946291171d579 AT mail DOT gmail DOT com> <2abc9c2d0806060116t2da2970as52d545f7a38560b7 AT mail DOT gmail DOT com>
MIME-Version: 1.0
In-Reply-To: <2abc9c2d0806060116t2da2970as52d545f7a38560b7@mail.gmail.com>
User-Agent: Mutt/1.5.16 (2007-06-09)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Fri, Jun 06, 2008 at 09:16:41AM +0100, Blair Sutton wrote:
>On further investigation, it appears powershell does alias "-c" for
>"-command" hence no changes would be required for cron to support it.
>However, the change would still be useful for other shells or perhaps
>interpreters like Perl.
>
>On Pierre's offered solution: I now do recall how exec works and it is
>correct that it replaces the current process - although a there will
>be some overhead. However, that begs the question why cron ever
>supported the SHELL parameter in the first place; if Mr Vixie wanted
>everyone to write a wrapper script using his preferred shell.

Mr.  Vixie rightly assumed that cron was running in a UNIX-like
environment where shells take the "-c" option.  Ditto the authors of
"make", "vim", and other packages which use the SHELL environment
variable.

Can we please put this to rest now?

cgf

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019