Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

samtregar (2699)

samtregar
  (email not shown publicly)
http://sam.tregar.com/

Journal of samtregar (2699)

Monday November 25, 2002
03:16 PM

Config::ApacheFormat 1.0

[ #9142 ]
I spent Sunday in a glorious coding haze. I'd gone to bed the previous night after realizing that Apache::ConfigFile won't work for my next project. My goal is to provide a configuration file in the same format as Apache's httpd.conf. Our sys admins are Apache experts, so using a similar config format will help them. Also, support for Include and a block structure with parameter inheritence should help a great deal in reducing the complexity of large configurations.

At first glance, Apache::ConfigFile looked the perfect fit. It parses Apache's config format and provides access to the results. Unfortunately, a closer look revealed:

  • a limited and strange API
  • a broken implementation of quoted strings
  • no support for parameter inheritence inside blocks
  • no tests!
  • funky code

Now, for a more complicated piece of functionality I might be inclined to stick it out and try to fix the module. But for this one the costs of working on old code definitely outweighed the benefits of building from scratch.

Thus, after a very enjoyable 4 solid hours of hacking, I give you Config::ApacheFormat, version 1.0. I hope you like it.

I'm always surprised by how much I really enjoy the act of creative programming. My day job is so often focused on designing, managing, bug fixing, etc. Writing new code reminds me that I really do like my job, the good part anyway.

-sam

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.