aboutsummaryrefslogtreecommitdiff
path: root/debian/rules
diff options
context:
space:
mode:
authorThomas Goirand <thomas@goirand.fr>2012-10-14 12:11:24 +0000
committerThomas Goirand <thomas@goirand.fr>2012-10-14 12:12:52 +0000
commit1e12955d5f9a2edaf757db343b1bd3626566b440 (patch)
treeace418175953d28e93cbf10bb03032e6cd86e491 /debian/rules
parentb54ff5c786dba08c5d35a0bc3e6dd1500c9fd7a0 (diff)
downloadfactory-boy-1e12955d5f9a2edaf757db343b1bd3626566b440.tar
factory-boy-1e12955d5f9a2edaf757db343b1bd3626566b440.tar.gz
* New upstream release.
* Added a get-vcs-source and debian/gbp.conf file. * Added everyone in the team as uploaders.
Diffstat (limited to 'debian/rules')
-rwxr-xr-xdebian/rules20
1 files changed, 18 insertions, 2 deletions
diff --git a/debian/rules b/debian/rules
index 206490c..8f89ae3 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,7 +1,23 @@
#!/usr/bin/make -f
-# Verbose mode
# export DH_VERBOSE=1
+DEBVERS := $(shell dpkg-parsechangelog | sed -n -e 's/^Version: //p')
+VERSION := $(shell echo '$(DEBVERS)' | sed -e 's/^[[:digit:]]*://' -e 's/[~-].*//')
+DEBFLAVOR :=$(shell dpkg-parsechangelog | grep -E ^Distribution: | cut -d" " -f2)
+DEBPKGNAME :=$(shell dpkg-parsechangelog | grep -E ^Source: | cut -d" " -f2)
+
%:
- dh $@ --with python2 \ No newline at end of file
+ dh $@ --with python2
+
+get-vcs-source:
+ git remote add upstream git://github.com/rbarrois/factory_boy.git || true
+ git fetch upstream
+ if [ ! -f ../$(DEBPKGNAME)_$(VERSION).orig.tar.xz ] ; then \
+ git archive --prefix=$(DEBPKGNAME)-$(VERSION)/ $(VERSION) | xz >../$(DEBPKGNAME)_$(VERSION).orig.tar.xz ; \
+ fi
+ if ! git checkout master ; then \
+ echo "No upstream branch: checking out" ; \
+ git checkout -b master upstream/master ; \
+ fi
+ git checkout debian/experimental