summaryrefslogtreecommitdiff
path: root/backend/update.py
diff options
context:
space:
mode:
authorKarl Semich <0xloem@gmail.com>2016-05-26 19:50:58 -0400
committerKarl Semich <0xloem@gmail.com>2016-05-26 19:50:58 -0400
commitb4f7e2b96c63504b4a949a67a80f88628d322dd9 (patch)
treef29e18d860692d55abb5b65dab92084ff8cadf2c /backend/update.py
parent7d4d389667d9f24a00b265c22fd39ff0f0d9c18a (diff)
downloadstandingwithresilience-b4f7e2b96c63504b4a949a67a80f88628d322dd9.tar.gz
standingwithresilience-b4f7e2b96c63504b4a949a67a80f88628d322dd9.zip
add updating script, including to freenet
Diffstat (limited to 'backend/update.py')
-rwxr-xr-xbackend/update.py25
1 files changed, 25 insertions, 0 deletions
diff --git a/backend/update.py b/backend/update.py
new file mode 100755
index 0000000..f605b39
--- /dev/null
+++ b/backend/update.py
@@ -0,0 +1,25 @@
+#!/usr/bin/env python2
+
+import os
+
+status = 0
+status += os.system("git pull git://standingwithresilience.branchable.com/")
+#status += os.system("git pull fairlystable-guest:/srv/git/standingwithresilience")
+
+if status != 0:
+ exit(status)
+
+status += os.system("git push git://standingwithresilience.branchable.com/")
+status += os.system("git gc --prune=0")
+
+if status != 0:
+ exit(status)
+
+status += os.system("ikiwiki --rebuild ../wiki ../html")
+
+if status != 0:
+ exit(status)
+
+status += os.system("freesitemgr -c freesitemgr -v -l freesitemgr.log -r 0 update")
+
+print "Done."