Sponsored Content
Full Discussion: variable substitution in ksh
Top Forums Shell Programming and Scripting variable substitution in ksh Post 302324660 by fpmurphy on Thursday 11th of June 2009 10:18:44 AM
Old 06-11-2009
The following also works
Code:
eval echo '${BIT'${SUBSET_BIT_NUM}'}'

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

ksh substitution

Hello, I thought it was possible to use several time a #! entry on a script but it doesn't seems to work. My need is to have a part of a ksh script without substitution so it would look like #!/bin/ksh -- first part --- #!/bin/ksh -f -- part without substitution -- #!/bin/ksh --... (2 Replies)
Discussion started by: solea
2 Replies

2. Shell Programming and Scripting

KSH variable substitution

Hi folks Please let me know if anyone knows how to handle this. My KSH script -> testscript.ksh cmd=$1 ENV="devl" echo $cmd This is how I call the script ./testscript.ksh 'ps -ef | grep br$ENV' How do I get this to print the below text i.e $ENV should be substituted with the value... (5 Replies)
Discussion started by: tipsy
5 Replies

3. AIX

Substitution not working in ksh

Following code is working in bash but not in ksh. Can someone please send me an alternative? #!/bin/ksh fname="EOA.dmp" echo $fname logname=${fname/.dmp/.log} echo $logname I am getting below error in ksh "testcmd: logname=${fname/.dmp/.log}: 0403-011 The specified substitution is not... (2 Replies)
Discussion started by: arsheshadri
2 Replies

4. Solaris

Substitution not working in ksh

Hi, Following code is working in bash but not in ksh. Can someone please send me an alternative? #!/bin/ksh fname="EOA.dmp" echo $fname logname=${fname/.dmp/.log} echo $logname I am getting below error in ksh "testcmd: logname=${fname/.dmp/.log}: 0403-011 The specified substitution... (3 Replies)
Discussion started by: arsheshadri
3 Replies

5. Shell Programming and Scripting

Double Substitution variables in ksh

Hi I have a variable whose value is like this i=/test/test1/test2/myfile.cd.070505123457 i would like to have the value of myfile.cd stored into another variable my attempt is test=${i##*/} ;echo $test ##and i get myfile.cd.070505123457 since what i wnat is myfile.cd i try this... (19 Replies)
Discussion started by: xiamin
19 Replies

6. Shell Programming and Scripting

Sed variable substitution when variable constructed of a directory path

Hello, i have another sed question.. I'm trying to do variable substition with sed and i'm running into a problem. my var1 is a string constructed like this: filename1 filerev1 filepath1 my var2 is another string constructed like this: filename2 filerev2 filepath2 when i do... (2 Replies)
Discussion started by: alrinno
2 Replies

7. Shell Programming and Scripting

bad substitution error in ksh

hi, i created a shell script having the following content: #! /usr/bin/ksh FROM="myemail@domain.com" MAILTO="someemail@domain" SUBJECT="TEST" BODY="/export/home/adshocker/body.txt" ATTACH="/export/home/adshocker/attach.prog" echo $ATTACH ATTACH_NAME="${ATTACH##*/}" echo $ATTACH_NAME... (5 Replies)
Discussion started by: adshocker
5 Replies

8. Shell Programming and Scripting

bad substitution error in ksh

Hello, In bash I can use the following: TMP=12345 MID=${TMP:1:1} the expected result is: 2 but when using KSH I'm getting a ''bad substitution" error. What is the correct syntaxin ksh? Thanks (2 Replies)
Discussion started by: LiorAmitai
2 Replies

9. Shell Programming and Scripting

Using Sed to do a substitution inside ksh

I'm trying to do an ls from inside of a ksh script. I loop through the results one line at a time and attempt to do a substitution using sed to convert YYYYMMDD from the older files into the newer files. Basically sometimes the ETL load runs over midnight and half the files are off by one day... (3 Replies)
Discussion started by: Calbrenar
3 Replies

10. Shell Programming and Scripting

Simple Variable substitution in ksh not working

Hi Gurus, Not able to catch what's going wrong here. I just want to get output as "tree". server:/mk/app/nexapp $ echo $SHELL /usr/bin/ksh server:/mk/app/nexapp $ export db_name1="tree" server:/mk/app/nexapp $ export i=1 1st try: server:/mk/app/nexapp $ echo $(db_name$i) ksh: db_name1: ... (3 Replies)
Discussion started by: mukesh.lalwani
3 Replies
LAX(5)							     CAO-VLSI Reference Manual							    LAX(5)

NAME
lax - Parameter file for logic synthesis ORIGIN
This software belongs to the ALLIANCE CAD SYSTEM developed by the ASIM team at LIP6 laboratory of Universite Pierre et Marie CURIE, in Paris, France. Web : http://asim.lip6.fr/recherche/alliance/ E-mail : alliance-users@asim.lip6.fr SYNOPSIS
filename.lax DESCRIPTION
The .lax file contains user modifiable parameters that lead to different logic synthesis. EXAMPLE
Circuit Interfce -- Entity Declaration ENTITY digia IS PORT ( clock : in BIT; -- clock jour : in BIT; -- jour reset : in BIT; -- reset vdd : in BIT; -- vdd vss : in BIT; -- vss i : in bit_vector(3 DOWNTO 0) ; -- i porte : out BIT; -- porte alarm : out BIT; -- alarm ep_0 : out BIT; -- ep_0 ep_1 : out BIT; -- ep_1 ep_2 : out BIT; -- ep_2 ep_3 : out BIT; -- ep_3 ep_4 : out BIT; -- ep_4 ep_5 : out BIT; -- ep_5 ep_a : out BIT -- ep_a ); END digia; -- Architecture Declaration ARCHITECTURE behaviour_data_flow OF digia IS SIGNAL cs : REG_VECTOR(0 TO 2) REGISTER; -- cs SIGNAL cs_ea : BIT; -- cs_ea SIGNAL ef_ea : BIT; -- ef_ea SIGNAL cs_e5 : BIT; -- cs_e5 SIGNAL ef_e5 : BIT; -- ef_e5 SIGNAL cs_e4 : BIT; -- cs_e4 SIGNAL ef_e4 : BIT; -- ef_e4 SIGNAL cs_e3 : BIT; -- cs_e3 SIGNAL ef_e3 : BIT; -- ef_e3 SIGNAL cs_e2 : BIT; -- cs_e2 SIGNAL ef_e2 : BIT; -- ef_e2 SIGNAL cs_e1 : BIT; -- cs_e1 SIGNAL ef_e1 : BIT; -- ef_e1 SIGNAL cs_e0 : BIT; -- cs_e0 SIGNAL ef_e0 : BIT; -- ef_e0 SIGNAL ef : BIT_VECTOR(0 TO 2); -- ef .Lax parameter file ## This line is a comment ## Set the Optimisation Mode (0..4) ## 0 : full area optimisation ## 2 : 50% area, 50% delay ## 4 : full delay optimisation ## Used by boog and loon #M{4} ## Set the Optimisation Level (1..5) ## 1 : poor optimisation - small computation time ## 5 : best optimisation - long computation time #L{5} ## External Input Delay (in ns) ## Those signals are taken into account to optimise ## the global delay of the circuit. ## Used by boog and loon #D{ i(3):300; i(0):100; jour:120; } ## Set the list of early outputs ## Some outputs may be critical. They can be ## optimized in delay before others regardless ## of the optimisation mode. #E{ porte; ep_3; } ## Set the list of auxiliary (intermediate) signals to keep ## This can be used to decrease the memory consuption ## when trying to reorder Bdds. Those signals wont ## be reordered. #S{ cs_ea; ef_0; ef_1; ef_e4; } ## The following parameters are used for whith glop ## (Delayed --#D--inputs are also used) ## Fanout factor : the max fanout of the ## output connector is multiplied by this factor #T{1000} ## Input Capacitance : The primary inputs of the circuit ## can have fanout values. (in fF) #F{ jour:50; } ## External Output Capacitance (in fF) ## Used by boog and loon #C{ porte:50; } ## External Input Impedance (in Ohms) ## Used by boog and loon #I{ jour:5000; } ## Buffered Input : this is a list of primary inputs whith ## the number of buffer you want to add. #B{ clock:1; } SEE ALSO
boom(1), boog(1). loon(1). BUG REPORT
This tool is under development at the ASIM department of the LIP6 laboratory. We need your feedback to improve documentation and tools. ASIM
/LIP6 October 1, 1997 LAX(5)
All times are GMT -4. The time now is 10:12 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy