News for hackers. Stuff that matters.
Re:Mongrel2 Says, "Goodbye Python" by mahmud on Tuesday September 21, 2010 @08:39AM (#1712364)
Instead of inventing your own syntax, why didn't you use a portable syntax like XML, JSON, YAML, or better yet, libconfig[1]?

Please compare the libconfig test file to the mongrel configuration file:

http://www.hyperrealm.com/libconfig/test.cfg.txt

http://mongrel2.org/doc/tip/docs/manual/book.wiki#x1-190003....

The mongrel conf is a subset of libconfig; it doesn't use the more advanced features. Plus libconfig has bindings and versions of it in nearly every mainstream language.

[1]http://www.hyperrealm.com/libconfig/libconfig.html

Re:Mongrel2 Says, "Goodbye Python" by alexgartrell on Tuesday September 21, 2010 @11:12AM (#1712875)
The mongrel2 configuration architecture makes it pretty easy to write a libconfig configuration shell. All it would need to do is translate the libconfig stuff to sqlite.

If using libconfig is a good idea, it'll win.

P.s. imho, this is the cool thing about the Mongrel2 stuff. The good ideas can always win, because there really just isn't a whole lot to Mongrel2-core, and everything else is decoupled.

Re:Mongrel2 Says, "Goodbye Python" by zedshaw on Tuesday September 21, 2010 @01:17PM (#1713340)
I thought about something like that, but wanted to duplicate the existing config file format so that people's configs would keep working (mostly). It actually had some cool advantages, like a nice psuedo variable system letting you setup variables for reuse in different parts of the config file.

I haven't really seen that in other config formats, and it is damn handy.

Re:Mongrel2 Says, "Goodbye Python" by mahmud on Tuesday September 21, 2010 @01:48PM (#1713434)
libconfig has include directives, is far more useful to multi-instance setups. Plus you get a full type system, all in a 33k binary.
Re:Mongrel2 Says, "Goodbye Python" by pygy_ on Wednesday September 22, 2010 @03:17AM (#1715427)
Re:Mongrel2 Says, "Goodbye Python" by thaumaturgy on Tuesday September 21, 2010 @02:26PM (#1713557)
I do that in the readable config file format I wrote for another web backend, and it is hella useful.