editing conf file

chip9munk "chip9munk[SSSpAm" at gmail.com
Fri Nov 16 13:06:07 CET 2012

Hi all!

I would like to use conf file to get all the variables in my code. And 
it works great. I use the following (simple example):

execfile("example.conf", config)
     print config["value1"]

and it works like a charm.

Now the problem is I do not know how to edit the conf file...
let us say that I calculate something and would like to save it in the 
conf file so that it is set for the next run of some program.

How do I edit a specific value in the conf file? (I would like to avoid 
editing txt if possible)...

I should also mention that I use Python 3.. so some of the solutions I 
came across are not compatible...


More information about the Python-list mailing list