Database creator for .po and .pot files



Hi!

Following  Edward's idea on a database to hold the information of the .po files so we can achieve a better consitency in our translations here is the first of a program which tries to do just that.
It takes a .po or .pot file and places it in a MySQL database so it be easily inspected and compared with other files.

Basically what the program do is adding a file or updating the database when the dates from the file are more recent than the database.

I'll post in the next days a program that recreates a .po file from the database.

At the mysql level the program creates 2 tables for each package under the database a user defined database (default is 'gnome_translations'). On of the tables holds the unstranslated strings (.pot files) and is called <pacakge_name>_orig. The other holds the translated files (.po) and is called <package_name>. 

	The table <package_name> is composed of 8 columns named: 
 - package_id (just an identifier for 'private' use)
 - string_id (another identifier)
  [and now the usefull stuff]
 - idiom (holds the language of the translated string)
 - string (msgstr)
 - creation (creation date of the pot file where this translation was based on)
 - revision (date of the last revision of the .po file)
 - hotkey_level (hopefully this field will be used to solve hotkey conflicts, but it has to be filled by humans)
 - notes (also to be filled by humans).

	The table <package_name>_orig is composed of 7 columns called:

 - package_id (blah..)
 - string_id (blah blah..)
   [and]
 - string (msgid)		
 - location (the location in the source)
 - creation (pot file creation date)
 - hotkey_level
 - notes (this contains the comments that the .pot file might had plus human added comments)

The program depends on libmysqlclient.
It is still probably full of bugs but i hope you'll help me find and kill them :-).
I also think the database could be made in a more efficient way (i already see 2 pointless columns) but we need to start from somewhere right?

I'll try to copy the entire gnome stable branch to the database, and recreate them from the database, in the next few days so i can test the program.

Now someone can start working on the web interface ;-).
Bye!

-- 
*----------------------------------------------------------------*
|  .''`.  | Filipe Maia                                          |
| : :'  : | email: fmaia@gmx.net                                 |
| `. `'`  |                                                      |
|   `-    | Debian GNU/Linux: <http://www.debian.org>            |
*----------------------------------------------------------------*

po2mysql-0.0.1.tar.gz



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]