Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sources.redhat.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@sources.redhat.com>
List-Help: <mailto:cygwin-help@sources.redhat.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@sources.redhat.com
Delivered-To: mailing list cygwin@sources.redhat.com
Date: Mon, 12 Mar 2001 17:38:40 +0200
Message-Id: <200103121538.RAA20010@linux.>
From: "Ehud Karni" <ehud@unix.simonwiesel.co.il>
To: galenboyer@yahoo.com
Subject: Re: KSH to Bash conversion
CC: cygwin@sourceware.cygnus.com
In-reply-to: <ur903uobj.fsf@yahoo.com> (message from Galen Boyer on 12 Mar
	2001 08:08:48 -0500)
Organization: Simon & Wiesel Insurance agency
Reply-to: ehud@unix.simonwiesel.co.il
References:  <ur903uobj.fsf@yahoo.com>
X-Mailer: Emacs 20.7.1 rmail (send-msg 1.104)
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-8
Content-Transfer-Encoding: 7bit

> 
> In KSH, I have the following statement:
> 
> typeset -u TableName=$2

THIS IS DEFINITELY OFF TOPIC. Please don't ask more bash questions here.

Anyway since you have done your noise, here are some answers.

1. To convert to upper case you can use `tr' like this:
       TableName=`echo "$2" | tr "[a-z]" "[A-Z]"`
   Please note all the " and ` - they are essential.

2. Echo of escaped (backslashed) characters.
   Beside the -e argument you can:
   2.1  Use /bin/echo
   2.2  Set the xpg_echo option (shopt -s xpg_echo)
   2.3  Compile bash with --enable-usg-echo-default

Remember in Cygwin sh is not bash (it is ash). You can change this by
removing/renaming sh and sym-linking bash to sh (that's what I do).

I STRONGLY suggest you read the bash man page(s) carefully.

Ehud.


-- 
 @@@@@@ @@@ @@@@@@ @    @   Ehud Karni  Simon & Wiesel  Insurance agency
     @    @      @  @@  @   Tel: +972-3-6212-757    Fax: +972-3-6292-544
     @    @ @    @ @  @@    (USA)  Fax  and  voice  mail:  1-815-5509341
     @    @ @    @ @    @        Better     Safe     Than     Sorry
 http://www.simonwiesel.co.il    mailto:ehud@unix.simonwiesel.co.il

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

