Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2001:
[Freeciv-Dev] Re: [PATCH] convert save_options() to secfile
Home

[Freeciv-Dev] Re: [PATCH] convert save_options() to secfile

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Freeciv-Dev <freeciv-dev@xxxxxxxxxxx>
Cc: bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: [PATCH] convert save_options() to secfile
From: Mike Kaufman <mkaufman@xxxxxxxxxxxxxx>
Date: Thu, 6 Dec 2001 19:20:31 -0600

here's another patch...

currently the client uses fprintf() to put options into .civclientrc
this patch changes this to secfile_insert_* etc, and does away with 
open_option_file() to boot.

pros:   consistency (somewhat lame, but alright)
        reduces code (a bit)
        allows one to easily save global worklists to file (good)

this last one is mainly what I'm aiming for. I personally think that
it's silly to have to create new global worklists every time I play.
It's almost not worth doing. Saving worklists to file would allow me to
do it once and then forget about it. More on this when I have code to
show.

oh yeah, there's a con with this patch:

con:
        current code puts a nice comment beside the message options.
        secfile_insert can't do this (if it can somebody show me how)
        so there's a kludge to make a comment. It gets the job done,
        but its not pretty. I don't think that the patch should be 
        rejected for this however.

-mike

Attachment: save_options.diff
Description: Text document


[Prev in Thread] Current Thread [Next in Thread]