weekly-update: Automatically commit ledger
authorNelson Elhage <nelhage@ksplice.com>
Fri, 14 May 2010 19:34:02 +0000 (15:34 -0400)
committerNelson Elhage <nelhage@ksplice.com>
Fri, 14 May 2010 19:34:02 +0000 (15:34 -0400)
weekly-update.py

index faa6c4cc42dd53f478398c2a126d7f09fc75957d..02cefca238c029d79faad4e0b0d7d5e0af2fdaf0 100755 (executable)
@@ -19,8 +19,12 @@ finally:
 x = xmlrpclib.ServerProxy(XMLRPC_ENDPOINT)
 
 with open('ledger', 'a') as f:
+    f.write("\n")
     f.write(render.render_template('templates/ledger', sys.argv[1]))
 
+subprocess.check_call(["git", "commit", "templates/ledger",
+                       "-m", "Update for %s" % (sys.argv[1],)])
+
 text = render.render_template('templates/week.tmpl', sys.argv[1])
 
 lines = text.split("\n")

Benjamin Mako Hill || Want to submit a patch?