Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Sun, 7 Dec 2003 01:57:48 +0100 (MET) From: svartsjel AT gmx DOT net To: cygwin AT cygwin DOT com MIME-Version: 1.0 Subject: bash loop troubles X-Priority: 3 (Normal) X-Authenticated: #624634 Message-ID: <20389.1070758668@www55.gmx.net> X-Flags: 0001 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit Hi, I tried to run the following bash script: for drive in a b c d e f g h i j k l m n o p q r s t u v w x y z do alias ${drive}:="cd /cygdrive/${drive}" done I guess, the syntax for the loop is okay, if I replace the alias line with a simple echo command: echo $drive I get a b ... and so on. Doing the following (both at the prompt and within a bash script): drive='c'; alias $drive:="cd /cygdrive/$drive" will lead to the alias as expected. Merely inside the loop it just doesn't seem to work. Any hints? Thanks in advance, Michael -- +++ GMX - die erste Adresse für Mail, Message, More +++ Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net -- 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/