[Frugalware-darcs] git-hooks: new plugin: sync the working dir after each push (just like in darcs)

VMiklos vmiklos at frugalware.org
Mon Jun 25 21:00:43 CEST 2007


Darcsweb-Url: http://darcs.frugalware.org/darcsweb/darcsweb.cgi?r=git-hooks;a=darcs_commitdiff;h=20070625194951-e2957-56fad2772c594f142b8e7b6d105d8764b229b6e7.gz;

[new plugin: sync the working dir after each push (just like in darcs)
VMiklos <vmiklos at frugalware.org>**20070625194951] {
adddir ./checkout
addfile ./checkout/__init__.py
addfile ./checkout/checkout.py
hunk ./checkout/checkout.py 1
+#!/usr/bin/env python
+
+import os
+
+first = True
+
+def callback(patch):
+	global first
+
+	if not first:
+		return
+	first = True
+	os.chdir("..")
+	del os.environ['GIT_DIR']
+	os.system("git checkout -f")
hunk ./config.py 4
-	enabled_plugins = ['cia', 'sendmail']
+	enabled_plugins = ['cia', 'sendmail', 'checkout']
}


More information about the Frugalware-darcs mailing list