[Python-checkins] r85148 - tracker/instances/python-dev/lib/identify_patch.py
martin.v.loewis
python-checkins at python.org
Fri Oct 1 23:04:36 CEST 2010
Author: martin.v.loewis
Date: Fri Oct 1 23:04:36 2010
New Revision: 85148
Log:
Convert to cron job.
Modified:
tracker/instances/python-dev/lib/identify_patch.py (contents, props changed)
Modified: tracker/instances/python-dev/lib/identify_patch.py
==============================================================================
--- tracker/instances/python-dev/lib/identify_patch.py (original)
+++ tracker/instances/python-dev/lib/identify_patch.py Fri Oct 1 23:04:36 2010
@@ -1,4 +1,5 @@
-import subprocess, re
+#!/usr/bin/python
+import subprocess, re, sys
from xml.etree import ElementTree
def identify(db, patch):
@@ -73,10 +74,12 @@
db.commit()
return branch
+# this runs as a cron job every 30min
if __name__=='__main__':
# manual setup:
# create table svnbranch(rev integer primary key, branch text);
# then run this once in the instance directory
+ sys.path.append('/home/roundup/roundup/lib/python2.5/site-packages')
import roundup.instance
tracker = roundup.instance.open('.')
db = tracker.open('admin')
More information about the Python-checkins
mailing list