[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: export won't work



"Eric G. Miller" wrote:
> 
> On Sun, Sep 01, 2002 at 07:04:07PM +1000, Russell wrote:
> > Hi,
> >
> > Why won't export work? When i run this
> > bash script on debian 3:
> >
> > #!/bin/sh
> > ABC=def
> > export ABC
> > exit 0
> >
> > when i type 'export', then ABC doesn't
> > appear in the list of environment variables.
> 
> A process can't change the environment of it's parent.  What are you
> trying to do?

I'm trying to export a variable so that i can see what it was
set to at that point in the script. What would be an easy way
to do this, without using "source ./script" ? I don't want to
use 'source', because i'd have to remove numerous exit statements,
to prevent killing the current shell.



Reply to: