[Thread Prev][Thread Next][Index]

Re: [ferret_users] Shell script arg not working as Ferret variable



Thanks, Russ! The \ didn't quite work because Ferret was reading everything after the variable substitution very literally. The eventual solution was: 
let p=${var1:h}[x=0:360,y=-90:90]

In cshell, the :h option gets rid of the default space at the end of every variable inserted. 

Thanks very much!!

-Eowyn 


----- Original Message -----
From: Russell Fiedler <russell.fiedler@xxxxxxxx>
Date: Tuesday, June 23, 2009 12:25 am
Subject: Re: [ferret_users] Shell script arg not working as Ferret variable
To: "Eowyn.Connolly-Brown@xxxxxxxx" <Eowyn.Connolly-Brown@xxxxxxxx>

> Hi,
> 
> Looks like you need to escape the shell
> 
> Try a backslash
> 
> yes? let p=$var1\[x=@ave,..]
> 
> Cheers,
> Russ
> 
> 
> On Tuesday 23 June 2009 12:43, you wrote:
> > Greetings Ferreteers,
> >
> > Hopefully this is a simple one:
> > I have a shell script that takes var1=$argv[1] as a user input, then
> > executes Ferret and carries out several ferret commands. I'm doing some
> > correlation plots, and need to say, eg, yes? let p=$var1[x=@ave, y=...]
> >
> > With this syntax (no space between var1 & [x), the unix shell (tsch)
> > executes the command to open ferret, but complains of "Missing -." 
> With a
> > space:
> > yes? let p=$var1 [x=@ave,..]
> > the shell is happy, but ferret has errors because it doesn't 
> recognize var1
> > [x=..] as a valid variable.
> >
> > Can I trick Ferret somehow?
> >
> > Many thanks!
> >
> > A humble newbie,
> > Eowyn


[Thread Prev][Thread Next][Index]

Contact Us
Dept of Commerce / NOAA / OAR / PMEL / TMAP

Privacy Policy | Disclaimer | Accessibility Statement