Back to index

moin  1.9.0~rc2
Functions | Variables
MoinMoin.i18n.tools.wiki2po Namespace Reference

Functions

def run

Variables

string master_url = "http://master19.moinmo.in/?action=xmlrpc2"
string DOMAIN = "MoinMoin"

Function Documentation

Definition at line 10 of file wiki2po.py.

00010 
00011 def run():
00012     import sys, xmlrpclib
00013     sys.path.insert(0, '../..')
00014 
00015     excluded = ["en", ] # languages managed in repository, not in wiki
00016 
00017     lang = sys.argv[1]
00018 
00019     if not lang in excluded:
00020         wiki = xmlrpclib.ServerProxy(master_url)
00021 
00022         pagename = "MoinI18n/%s" % lang
00023         print pagename
00024         pagedata = wiki.getPage(pagename).encode('utf-8').replace("\n", "\r\n")
00025 
00026         f = open("%s.%s.po" % (lang, DOMAIN), "w")
00027         f.write(pagedata)
00028         f.close()


Variable Documentation

Definition at line 8 of file wiki2po.py.

string MoinMoin.i18n.tools.wiki2po.master_url = "http://master19.moinmo.in/?action=xmlrpc2"

Definition at line 6 of file wiki2po.py.