Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-ID: <3946881E.2C8F0DBC@veritas.com> Date: Tue, 13 Jun 2000 12:14:38 -0700 From: Bob McGowan Organization: VERITAS Software X-Mailer: Mozilla 4.73 [en] (WinNT; U) X-Accept-Language: en MIME-Version: 1.0 To: Dan Holmsand CC: Cygwin mailing list , bug-bash AT gnu DOT org Subject: Re: shift: can't shift that many References: <000501bfd565$597de7e0$a7d396c1 AT inneh3> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Transfer-Encoding: 7bit Dan Holmsand wrote: > > Actually, I think cygwin's sh is quite right - xemacs' installexe.sh tries > to shift three args where there's only two. Changing "shift 2" to just > "shift" in line 12 gets rid of the error message. > > /dan > > > -----Original Message----- > > From: owner-xemacs-nt AT xemacs DOT org [mailto:owner-xemacs-nt AT xemacs DOT org]On > > Behalf Of John A. Turner > > Sent: den 13 juni 2000 14:03 > > To: XEmacs on NT; Cygwin mailing list; bug-bash AT gnu DOT org > > Subject: Re: shift: can't shift that many > > > > > > "John A. Turner" wrote: > > > > > > I've successfully built a cygwin version of XEmacs 21.2.34 > > > > > > however, during make install, I get lots of msgs from bash related > > > to the shift built-in - as in the subject: > > > > > > shift: can't shift that many > > > > never mind - I can't believe this, but I've been bitten by the > > "sh is really ash" feature in cygwin > > > > I've been using cygwin long enough to know better, but somehow > > after an update I forgot to fix that > > The following script: echo $# shift 3 echo $# echo shifting two more: shift 2 echo $# Produces the following output for sh (ash) and bash: $ sh shiftest a b c d 4 1 shifting two more: shift: can't shift that many 1 $ bash shiftest a b c d 4 1 shifting two more: 1 The only difference is the error message generated by ash. The final result is the same, the last shift did not change the argument count. I don't think this is a bug in either of shells, unless you want to count not printing an error as the bug. It is a bug in the original script, however. -- Bob McGowan Staff Software Quality Engineer VERITAS Software rmcgowan AT veritas DOT com -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com