From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 0D4F4BB9B for ; Tue, 27 Sep 2005 19:02:34 +0200 (CEST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id j8RH2XVt015243 for ; Tue, 27 Sep 2005 19:02:33 +0200 Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id TAA00425 for ; Tue, 27 Sep 2005 19:02:33 +0200 (MET DST) Received: from mail21.sea5.speakeasy.net (mail21.sea5.speakeasy.net [69.17.117.23]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j8RH2Ujo013613 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 27 Sep 2005 19:02:32 +0200 Received: (qmail 16874 invoked from network); 27 Sep 2005 17:02:29 -0000 Received: from shell4.sea5.speakeasy.net ([69.17.116.5]) (envelope-sender ) by mail21.sea5.speakeasy.net (qmail-ldap-1.03) with AES256-SHA encrypted SMTP for ; 27 Sep 2005 17:02:29 -0000 Date: Tue, 27 Sep 2005 10:02:29 -0700 (PDT) From: brogoff To: David MENTRE Cc: caml-list Subject: Re: [Caml-list] Looking for a configuration file library In-Reply-To: <3d13dcfc05092706091acdb72a@mail.gmail.com> Message-ID: References: <3d13dcfc05092706091acdb72a@mail.gmail.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Miltered: at concorde with ID 43397B29.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 43397B26.002 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 ocaml:01 ocaml:01 depencies:01 depencies:01 hashtbl:01 config:01 contrib:01 c--:01 config:01 noweb:01 noweb:01 2005,:98 wrote:01 computation:01 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.3 On Tue, 27 Sep 2005, David MENTRE wrote: > Hello, > > For easy configuration of my programs, I'm looking for some OCaml code > to read and write a user configuration file. > > Currently, I have following requirements: > > - pure OCaml, without depencies on other libraries (I have enough > depencies in my program); > > - allows human readable and editable configuration files (i.e. no > XML), preferably structured; > > - (preferably) allows to easily load and save OCaml data structure, > like Hashtbl. > > On the Hump, I found Config_file: > http://caml.inria.fr/cgi-bin/hump.fr.cgi?contrib=335 > > Any other suggestion? David, I like the Lua-ML package used in C--. Lua is just about right as a configuration language, especially if you wish to do some computation in your config file. It should satisfy your listed requirements. On the minus side IMO (I hate to be negative about something free) it uses noweb, and is not up to date with the latest version of Lua. In particular, the use of noweb is annoying, but with a bit of grunt work you can undo that. -- Brian