discuss-gnustep
[Top][All Lists]
Advanced

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

RE: environment variables vs defaults


From: ian . mondragon
Subject: RE: environment variables vs defaults
Date: Wed, 3 Jan 2001 12:20:51 -0600

as for the debian issue, i have absolutely NO clue - i run freebsd almost
exclusively.  the driving force behind what i envision this project becoming
is simply that i'm sick of .rc, .conf, .whatever files.  i think the NeXT
defaults database was a brilliant idea in many ways and think it should be
not only kept very alive, but extended to be used in ways that would benefit
the system (whether that be darwin/os x or a bsd/linux system running
GNUstep).  

therefore, the project that i started (which i am tentatively calling
GNUSys) is not just an env-to-defaults tool, but rather a 3-level system
that will use the standard *user* defaults database for (1) initializing
environment variables <level 1>, and (2) storing application settings as a
replacement for .rc & .conf files in a user's home directory <level 2>.
obviously, this second level will either require a severe hack to access the
defaults for an application (i.e. mutt) and provide an object that makes the
app think it's reading it's native configuration file (i.e. .muttrc), or a
partial rewrite of the application's method(s) for gathering default
settings.

the third level is a defaults database for the system itself, obviously
protected from evil hackery as much as possible, that provides the same
functionality for system applications/processes as level 2 does for user
applications.

not a small task by any means, but i (for some masochistic & possibly
foolish reason :-) see merrit in it, even if the payoff may only be patting
my own back (or kicking myself repeatedly).  there will be details of the
design & progress on my website (http://www.dragonhelix.org) when i get
around to it.

please feel free to offer suggestions...

- ian mondragon

> -----Original Message-----
> From: Jeff Sciortino [SMTP:address@hidden
> Sent: Wednesday, January 03, 2001 11:53 AM
> To:   Mondragon, Ian; address@hidden;
> address@hidden
> Cc:   address@hidden
> Subject:      Re: environment variables vs defaults
> 
> I think this issue has been a problem with running a consistent, legal
> port 
> on Debian, which I understand deplores the use of environment variables
> for 
> some of the reasons you cited.
> 
> A few applications I use (namely cdrecord) use files in the directory 
> /etc/defaults/ to record the defaults as an option to using environment 
> varables. (e.g. cdrecord's defaults are in the file /etc/default/cdrecord
> ;-)
> 
> How hard would it be to integrate something like this into GNUstep? My
> (very 
> limited) understanding is that it would make the Debian package much
> simpler.
> 
> Best Regards,
> 
> -Jeff
> 
> On Wednesday 03 January 2001 12:30, address@hidden wrote:
> > all -
> >
> >   while not *darwin* specific, i have been eagerly hacking away at
> > prototype versions of a utility that would effectively utilize the user
> > defaults database for setting environment variables in a
> shell-independant
> > manner - but all of my work is currently being done using the GNUstep
> API
> > as i don't have the $3000 to drop on the purty G4 i've been drooling
> over. 
> > the project is in a horribly pre-alpha stage as i just started it the
> other
> > week, but i'm sure that it would not be too much of a chore to port it
> over
> > to OS X once it (a) is more of a reality and (b) has a mac to function
> on
> > in my home.
> >
> > (yes, another ian)
> > - ian mondragon
> >
> > > -----Original Message-----
> > > From:     Ian P. Cardenas [SMTP:address@hidden
> > > Sent:     Tuesday, January 02, 2001 1:41 PM
> > > To:       address@hidden
> > > Subject:  environment variables vs defaults
> > >
> > > Hi all,
> > >
> > >   Has there been any discussion in providing OSX-style user defaults
> > > to
> > > traditional UNIX applications?  Specifically, there are things like
> cvs's
> > > CVS_RSH environmental variable that I would like every cvs application
> > > running for my user to have access to.  For a particular shell, I can
> > > have
> > >
> > > this variable set in the .bashrc, .cshrc, etc.  However, if some
> > > application that uses a different environment (or no shell, as in the
> > > case
> > >
> > > of a Workspace launched process) launches cvs it will not have this
> > > variable set.  What I think makes sense is to have some universally
> > > available service for environmental variables.  Then there could be
> one
> > > place that a user sets the variable and it would be available to all
> > > shells
> > > and all processes.  MacOS X provides exactly such a service in
> > > CoreFoundation's Preference Services.
> > >
> > >
> http://developer.apple.com/techpubs/macosx/CoreFoundation/PreferenceServi
> > >c es/Preference_Services/index.html
> > >
> > > Does anyone have any comments on how UNIX environment variables and
> > > CoreFoundation could be integrated?  My initial thought was to do so
> at
> > > the
> > > getenv() level in stdlib.  If getenv was modified to do a Preference
> > > lookup
> > > upon a failure to locate a variable in the environment that would be a
> > > simple method of integration.  This would allow a user to do something
> > > like:
> > >
> > > defaults write cvs CVS_RSH ssh
> > >
> > >   What do other people think?  From looking at the projects list for
> > > Darwin
> > > it seems like CoreFoundation is not part of Darwin.  If that's
> correct,
> > > this might only be of interest to MacOS X users.  Perhaps, I just see
> the
> > > problem differently because of my background.  How do X11 apps
> launched
> > > from a window manager handle this?
> > >
> > > --
> > > Ian P. Cardenas
> > > _______________________________________________
> > > darwin-development mailing list
> > > address@hidden
> > > http://www.lists.apple.com/mailman/listinfo/darwin-development
> >
> > _______________________________________________
> > Discuss-gnustep mailing list
> > address@hidden
> > http://mail.gnu.org/mailman/listinfo/discuss-gnustep



reply via email to

[Prev in Thread] Current Thread [Next in Thread]