[ale] scripts

Lisa Chiang gt6492d at gatech.campus.mci.net
Wed May 13 09:42:36 EDT 1998


I need some advice.  I am currently using bash shell scripts to parse a text
file that contains configuration info, for example, each line may contain two
numbers representing energy and thickness.

I feed these two variables into a gawk script which replaces all occurances of
these variables in a template file with the actual data I've just parsed from
the configuration file.  Now I finally call a program (MCNP) that executes with
the newly created input file.  This process is repeated for each line in the
configuration file.

I've got his working but shell scripts seem awkward and a little bit kludgy. 
Would Perl be able to open a file, parse it for certain data (similar to gawk)
and then pass the parsed data to an external program (gawk), a shell script or
an executable?  Hope this makes sense but I'm trying to avoid writing a C
program as this takes longer and warp speed is not required.

Thanks.

 --
gt6492d at gatech.campus.mci.net
Lisa Chiang






More information about the Ale mailing list