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

Re: .ini files in bash?



On Mon, Nov 29, 2004 at 04:02:15PM +0200, David Baron wrote:
> On Monday 29 November 2004 15:11, debian-user-digest-request@lists.debian.org 
> wrote:
> > Create a seperate rc file (.scriptrc ?) and have FOO=BAR in that, then
> > source the file in your script
> >
> > eg..
> >
> > [ .scriptrc ]
> >
> > FOO=BAR
> >
> >
> >
> > [ script ]
> >
> > source .scriptrc
> > echo $BAR
> 
> This is what I do once I have the file .scriptrc (should this be 
> ~/.scriptrc ?)
> 
> How do I save the values (which I might have changed in the script's menus) 
> when I  end.

------
X=$(cat singlevaluefile)
.... many statments 
do stuff
echo $X>singlevaluefile
------
HTH
-Kev
-- 
counter.li.org #238656 -- goto counter.li.org and be counted!

        (__)
        (oo)
  /------\/
 / |    ||
*  /\---/\
   ~~   ~~
...."Have you mooed today?"...

Attachment: signature.asc
Description: Digital signature


Reply to: