469,332 Members | 6,650 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,332 developers. It's quick & easy.

PyINI : Cross-Platform INI parser

hi, every one,

I started a opensource project PyINI for corss-platform *.ini parsing at
http://sourceforge.net/projects/pyini/

I have released a simple alpha version, which can read *.ini, with some
extended features such as "key=value1,value2,value3". I also made a
c++ binding to PyINI with elmer toolkit.

Yours,
SeSe
Jul 18 '05 #1
7 3917
SeSe wrote:
hi, every one,

I started a opensource project PyINI for corss-platform *.ini parsing
at http://sourceforge.net/projects/pyini/

I have released a simple alpha version, which can read *.ini, with
some extended features such as "key=value1,value2,value3". I also
made a c++ binding to PyINI with elmer toolkit.

The most useful feature would be to be able to write INI files back without
affecting their formatting, without removing user commands, etc. This is what
Windows APIs do, and it is what I am missing from most INI parsing libraries
out there.
--
Giovanni Bajo
Jul 18 '05 #2
Hello,
I started a opensource project PyINI for corss-platform *.ini parsing at
http://sourceforge.net/projects/pyini/

How it is different from http://docs.python.org/lib/module-ConfigParser.html?

Dalius
Jul 18 '05 #3
"Giovanni Bajo" <no***@sorry.com> writes:
SeSe wrote:
hi, every one,

I started a opensource project PyINI for corss-platform *.ini parsing
at http://sourceforge.net/projects/pyini/

I have released a simple alpha version, which can read *.ini, with
some extended features such as "key=value1,value2,value3". I also
made a c++ binding to PyINI with elmer toolkit.

The most useful feature would be to be able to write INI files back without
affecting their formatting, without removing user commands, etc. This is what
Windows APIs do, and it is what I am missing from most INI parsing libraries
out there.


You can easily access the windows apis either with pywin32, or with
ctypes for those functions that aren't wrapped in pywin32.

Thomas
Jul 18 '05 #4

Giovanni Bajo wrote:
SeSe wrote:
hi, every one,

I started a opensource project PyINI for corss-platform *.ini parsing at http://sourceforge.net/projects/pyini/

I have released a simple alpha version, which can read *.ini, with
some extended features such as "key=value1,value2,value3". I also
made a c++ binding to PyINI with elmer toolkit.

The most useful feature would be to be able to write INI files back

without affecting their formatting, without removing user commands, etc. This is what Windows APIs do, and it is what I am missing from most INI parsing libraries out there.
--
Giovanni Bajo


ConfigObj easily writes back, files but doesn't *yet* support the full
'ini' file spec (empty values and split lines it doesn't yet support).
These are targetted for next release.

What aspects of formatting do you want to keep, and I'll try and
include them ?

http://www.voidspace.org.uk/python/configobj.html

Regards,
Fuzzy
http://www.voidspace.org.uk/python/index.shtml

Jul 18 '05 #5
SeSe schrieb:
I started a opensource project PyINI for corss-platform *.ini parsing at
http://sourceforge.net/projects/pyini/

I have released a simple alpha version, which can read *.ini, with some
extended features such as "key=value1,value2,value3". I also made a
c++ binding to PyINI with elmer toolkit.


I suggest that you have a look at Tim Daneliuk's tconfpy serving a
similar purpose. Perhaps you can join forces.

I'd like to see a configuration tool that for Python programmers
is as easy as config.py, i.e. you you have config object and can
write/read it to/from some storage, e.g.

- .ini files
- Java config files
- xml files
- LDAP server
- win32 registry
- ...

It would be nice to make this not a Python only thing but accessible
by other languages like Perl, Ruby, Java, C/C++ ...

I think that a new config utility is worth the effort if it has the
potential to put an end to roll-your-own config formats and parsers.

--
-------------------------------------------------------------------
Peter Maas, M+R Infosysteme, D-52070 Aachen, Tel +49-241-93878-0
E-mail 'cGV0ZXIubWFhc0BtcGx1c3IuZGU=\n'.decode('base64')
-------------------------------------------------------------------
Jul 18 '05 #6
Peter Maas wrote:
I think that a new config utility is worth the effort if it has the
potential to put an end to roll-your-own config formats and parsers.


http://www.python.org/moin/ConfigParserShootout

Cheers,
Nick.

--
Nick Coghlan | nc******@email.com | Brisbane, Australia
---------------------------------------------------------------
http://boredomandlaziness.skystorm.net
Jul 18 '05 #7
Thomas Heller wrote:
I have released a simple alpha version, which can read *.ini, with
some extended features such as "key=value1,value2,value3". I also
made a c++ binding to PyINI with elmer toolkit.

The most useful feature would be to be able to write INI files back
without affecting their formatting, without removing user commands,
etc. This is what Windows APIs do, and it is what I am missing from
most INI parsing libraries out there.


You can easily access the windows apis either with pywin32, or with
ctypes for those functions that aren't wrapped in pywin32.


Sure, but we were speaking of doing that in a portable library.
--
Giovanni Bajo
Jul 18 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by rollasoc | last post: by
1 post views Thread by Rob Woodworth | last post: by
6 posts views Thread by Bart Van der Donck | last post: by
6 posts views Thread by ampo | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
1 post views Thread by haryvincent176 | last post: by
reply views Thread by Marylou17 | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.