Re: [RFC/PATCHv3] git-instaweb: Add support for running gitweb via 'plackup'

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

 



2010/5/22 Jakub Narebski <jnareb@xxxxxxxxx>:
> Webrick, which is in similar situation, uses httpd.conf config file in
> YAML.  Unfortunately there is no config / serialization reader in Perl
> core, so if we have to go this route either the config file would have
> to be in Perl, or gitweb.psgi wrapper would have to include some simple
> config file parsing.

You could easily do (pseudocode):

    unless (eval { require Config::Any; 1 }) {
        do $conf_file;
    } else {
        my $parser = Config::Any->new( ... );
         $parser->docnf( $conf_file );
     }

Then you'd read (eval) a perl config file by default, but remain
compatible with saner config formats for users prepared to install
things from the CPAN.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]