]> projects.mako.cc - iron-blogger/blob - update-participants.py
code changes to iron blogger to move to mako.cc
[iron-blogger] / update-participants.py
1 #!/usr/bin/python
2
3 import render
4 import os
5 import sys
6 import xmlrpclib
7 import subprocess
8
9
10 XMLRPC_ENDPOINT = 'http://iron-blogger.mako.cc/xmlrpc.php'
11 USER            = 'mako'
12 BLOG_ID         = 1
13 PAGE_ID         = 12
14
15 try:
16     subprocess.call(['stty', '-echo'])
17     passwd = raw_input("Password for %s: " % (USER,))
18     print
19 finally:
20     subprocess.call(['stty', 'echo'])
21
22 x = xmlrpclib.ServerProxy(XMLRPC_ENDPOINT)
23 page = x.wp.getPage(BLOG_ID, PAGE_ID, USER, passwd)
24
25 text = render.render_template('templates/users.tmpl')
26 page['description'] = text
27
28 x.wp.editPage(BLOG_ID, PAGE_ID, USER, passwd, page, True)

Benjamin Mako Hill || Want to submit a patch?