chiark / gitweb /
factor out exporting of quilt series to make snippet
authormartin f. krafft <madduck@debian.org>
Mon, 17 Nov 2008 22:24:12 +0000 (23:24 +0100)
committermartin f. krafft <madduck@debian.org>
Mon, 17 Nov 2008 22:33:33 +0000 (23:33 +0100)
Signed-off-by: martin f. krafft <madduck@debian.org>
debian/rules
debian/topgit.mk [new file with mode: 0644]

index d331f9234d61afd344348533e7ca6a937300cf55..74e8edd9e256edaf9097e5796ca71569faca24fe 100755 (executable)
@@ -4,6 +4,7 @@
 #export DH_VERBOSE=1
 
 include /usr/share/quilt/quilt.make
+include debian/topgit.mk
 
 build: build-stamp
 build-stamp: patch
diff --git a/debian/topgit.mk b/debian/topgit.mk
new file mode 100644 (file)
index 0000000..86099ff
--- /dev/null
@@ -0,0 +1,8 @@
+tg-export: TG_BRANCHES ?= $(shell tg summary -t)
+tg-export: __TG_SUBST_COMMA := ,
+tg-export: __TG_SUBST_EMPTY :=
+tg-export: __TG_SUBST_SPACE := $(__TG_SUBST_EMPTY) $(__TG_SUBST_EMPTY)
+tg-export:
+       test -d debian/patches && rm -r debian/patches || :
+       tg export -b $(subst $(__TG_SUBST_SPACE),$(__TG_SUBST_COMMA),$(TG_BRANCHES)) --quilt debian/patches
+.PHONY: tg-export