[Bioperl-l] directory for config files

Lincoln Stein lstein at cshl.org
Thu Apr 3 12:29:46 EST 2003


To me, Windows .INI file format is a reasonable compromise between 
readability, editability and expressivity.  XML format is nice in theory, but 
I hate working with it in practice.  Compare the config files for mysql (.ini 
format) and for Apache Tomcat (XML format).

There's a nice perl module for working with a variety of config file formats, 
including .INI.

Lincoln

On Wednesday 02 April 2003 07:26 am, Heikki Lehvaslaiho wrote:
> (You must be getting tired of my tirades. Sorry.) Seriously, it is
> post.1.2.1, new things have to be discussed and added.
>
>
> We should have directory under for config files and small data files.
> Bioperl is already using one for the sequence database registry which is
> bit of a special case as it is cross-platform project (see below) and
> fetches its default file from the net. Normally, you'd have:
>
> 1. System wide default location     # populated by 'make install'?
> 2. subdirectory under %HOME         # copied from  #1 and modified by
>                                     # user choices
> 3. ENV variable overriding the previous
>
>
> The need to this file came from Martin Senger who that he'd like to add
> a config file for his SOAPLab client and put it somewhere into the
> distribution.
>
> The other config files should follow the same location finding schema as
> the registry file, but they are free from registry format limitations.
> What I understood from Martin, is that he is planning to use directly
> perl code as format since the file is read and written only by his
> program.
>
> The choise of format can be quite controversial, and perhaps we do not
> have to decide anything on that. Two notes:
> 1. http://www.catb.org/%257Eesr/writings/taoup/html/ch05s02.html
> 2. YAML, www.yaml.org
>
> Alternative to files in a distribution directory is to keep the data
> inline and create the file into user's home directory when ranfor first
> time.
>
> Discuss.
>
> 	-Heikki
>
>
>
> from doc/howto/BIODATABASE_ACCESS.txt:
> #####################################################################
> The registry file should be named seqdatabase.ini.  By default, it
> should be installed in one of the following locations:
>
>    $HOME/.bioinformatics/seqdatabase.ini
>    /etc/bioinformatics/seqdatabase.ini
>
> The Bio{Perl,Java,Python,Ruby} registry-handling code will initialize
> itself from the registry file located in the home directory first,
> followed by the system-wide default in /etc.
>
> If a local registry file cannot be found, the registry-handling code
> will take its configuration from the file located at this URL:
>
>    http://www.open-bio.org/registry/seqdatabase.ini
>
>
> MODIFYING THE SEARCH PATH
>
> The registry file search path can be modified by setting the
> environment variable OBDA_SEARCH_PATH.  This variable is a "+"
> delimited string of files and URLs, for example:
>
>
> OBDA_SEARCH_PATH=/home/lstein/seqdatabase.ini+http://foo.org/seqdatabase.in
>i
>
> The search order proceeds from left to right.  The first file or URL
> that is found ends the search.
>
> #####################################################################

-- 
========================================================================
Lincoln D. Stein                           Cold Spring Harbor Laboratory
lstein at cshl.org			                  Cold Spring Harbor, NY
========================================================================




More information about the Bioperl-l mailing list