From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Neil Holmes" Subject: RE: ash and String Manipulation Date: Mon, 6 Jan 2003 11:12:27 -0000 Sender: linux-8086-owner@vger.kernel.org Message-ID: References: Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Id: Content-Type: text/plain; charset="us-ascii" To: jb1@btstream.com Cc: Linux 8086 Thanks for this. I am now working on alternative ways. Looks like I am having to flex my not-so-advanced 'C' skills ! Its going well though. Thanks Neil -----Original Message----- From: linux-8086-owner@vger.kernel.org [mailto:linux-8086-owner@vger.kernel.org]On Behalf Of jb1@btstream.com Sent: 04 January 2003 09:50 To: Neil Holmes Cc: Linux 8086 Subject: Re: ash and String Manipulation On Fri, 3 Jan 2003, Neil Holmes wrote: > Not sure if there is anyone out there in elks-land that can make some > suggestions here ? ... > Here is a segment of a test script from my EDE Package work :- > > string="advent,Text Adventure Game,advent.tar" > a=`expr index "$string" ,` > title=${string:0:$a-1} ... ... > "expr index" command does work but I don't seem to be able to find enough My RedHat 7.0 installation has /usr/bin/expr (and /bin/ash). Changing: a=`expr index "$string" ,` to: a=`/usr/bin/expr index "$string" ,` gives the same result when the first line of the script is: #!/bin/ash as the original line does when the first line of the script is: #!/bin/bash ELKS doesn't seem to have the external "expr" executable but, since it's part of RedHat's "sh-utils" package, Linux source code should be easy to find. I have no idea if it needs modification to compile for ELKS. Unfortunately, "${ ... }" still doesn't work. You might have to find some other external executable(s) for those lines. - To unsubscribe from this list: send the line "unsubscribe linux-8086" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html