[Pkg-mozext-commits] [torbirdy] 06/08: Add README.source

Jacob Appelbaum error at moszumanska.debian.org
Fri Oct 24 17:18:13 UTC 2014


This is an automated email from the git hooks/post-receive script.

error pushed a commit to branch master
in repository torbirdy.

commit 0b34b4ec9488d027ca26fc6f6f5512e43a741c9e
Author: Jacob Appelbaum <jacob at appelbaum.net>
Date:   Fri Oct 24 17:04:25 2014 +0000

    Add README.source
---
 debian/README.source | 145 +++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 145 insertions(+)

diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..693d351
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,145 @@
+# So you want to build a new Debian package for TorBirdy?
+# These are the exact steps taken to update from TorBirdy 0.1.2 to 0.1.3
+# 
+sudo apt-get install git-buildpackage pristine-tar mozilla-devscripts zip
+export VERSION=0.1.3
+git clone ssh://anonscm.debian.org/git/pkg-mozext/torbirdy.git torbirdy
+cd torbirdy
+git checkout upstream
+git checkout pristine-tar
+git checkout master
+cd ..
+git clone git at github.com:ioerror/torbirdy.git torbirdy.upstream
+cd torbirdy.upstream
+git checkout $VERSION
+git archive --format=tar --prefix="torbirdy_$VERSION.orig/" \ 
+  -o ../torbirdy_$VERSION.orig.tar -v $VERSION
+cd ../torbirdy
+git checkout master
+git import-orig --filter=*.git --pristine-tar --upstream-version=$VERSION \
+  ../torbirdy_$VERSION.orig.tar
+dch -v $VERSION-1 "New upstream release"
+git add debian/changelog
+git commit -m "stage release $VERSION"
+# Make any other changes here ...
+# stage them and commit them ...
+# Now build it and ignore anything not in git:
+git-buildpackage --git-ignore-new
+# Test the resulting .deb
+# Please tag this release, build and upload the Debian package
+# Hooray!
+# You're done!
+
+#########################################################################
+# The following notes are different ways to accomplish the same job
+# They are potential alternative methods for doing the task above
+# in the future.
+#########################################################################
+
+# First install some packages to do the job:
+sudo apt-get install git-buildpackage pristine-tar mozilla-devscripts zip
+# Or if using schroot
+mysid=sid$RANDOM;
+schroot -b -c sid -n $mysid; dd-schroot-cmd -c $mysid apt-get update;
+dd-schroot-cmd -c $mysid apt-get build-dep torbirdy;
+dd-schroot-cmd -c $mysid apt-get install git git-buildpackage \
+  pristine-tar mozilla-devscripts zip ssh ca-certificates gitpkg
+schroot -r -c $mysid
+
+# Lunar suggests the following as the ideal workflow
+# You may need to do this: gpg --recv-key 0x744301A2
+# Set the version we're going to import
+VERSION=0.1.3
+gbp clone https://anonscm.debian.org/git/pkg-mozext/torbirdy.git
+# Or if you're doing this with ssh keys:
+# gbp clone ssh://anonscm.debian.org/git/pkg-mozext/torbirdy.git
+cd torbirdy
+git remote add torbirdy-upstream https://github.com/ioerror/torbirdy.git
+# Or if you're doing this with ssh keys:
+# git remote add torbirdy-upstream ssh://git@github.com:ioerror/torbirdy.git
+git fetch torbirdy-upstream
+git tag -v $VERSION
+git checkout upstream
+git merge --ff-only $VERSION
+git tag upstream/$VERSION
+git checkout master
+git merge upstream/$VERSION
+# Make any packaging changes here (eg: dch, etc)
+git-buildpackage --git-ignore-new
+
+##########################################
+# Alternative ways to build this package #
+##########################################
+
+# Grab the current package's source:
+git clone ssh://anonscm.debian.org/git/pkg-mozext/torbirdy.git torbirdy
+# OR perhaps https://anonscm.debian.org/git/pkg-mozext/torbirdy.git
+# checkout the various branches:
+cd torbirdy
+git checkout upstream
+git checkout pristine-tar
+git checkout master
+# Grab upstream's latest git repo:
+cd ..
+git clone ssh://git@github.com:ioerror/torbirdy.git torbirdy.upstream
+# OR perhaps https://github.com/ioerror/torbirdy.git
+# Now create an orig.tar.bz of the upstream release
+cd torbirdy.upstream
+git checkout $VERSION # This is to ensure that we create a .tar of tag $VERSION
+# Make a pristine tarball from the upstream repo:
+git archive --format=tar --prefix="torbirdy_$VERSION.orig/" \ 
+  -o ../torbirdy_$VERSION.orig.tar -v $VERSION
+# Now import it
+cd ../torbirdy
+git checkout master
+git import-orig --filter=*.git --pristine-tar --upstream-version=$VERSION \
+  ../torbirdy_$VERSION.orig.tar
+# update the debian/changelog
+dch -v $VERSION-1 "New upstream release"
+# Commit the changes
+git add debian/changes
+git commit -m "stage release $VERSION"
+# Now build it and ignore anything not in git:
+git-buildpackage --git-ignore-new
+
+######################################
+# Git expert version follows:        #
+######################################
+git clone https://anonscm.debian.org/git/pkg-mozext/torbirdy.git
+cd torbirdy
+git checkout upstream
+git checkout pristine-tar
+git checkout master
+git remote add torbirdy.upstream https://github.com/ioerror/torbirdy.git
+git fetch torbirdy.upstream
+git checkout $VERSION
+git checkout -b $VERSION-merge-madness
+git merge -m 'directed acyclic graph trick' upstream -s ours
+git branch -m upstream old-upstream
+git branch -m $VERSION-merge-madness upstream
+git branch -d old-upstream
+git checkout upstream
+git checkout master
+# update the debian/changelog
+dch -v $VERSION-1 "New upstream release"
+# Commit the changes
+git add debian/changes
+git commit -m "stage release $VERSION"
+# Merge upstream into master
+git merge upstream
+# create the pristine-tar in ../deb-packages/torbirdy/torbirdy_$VERSION.orig.tar.gz
+# this also creates a source package in ../deb-packages/torbirdy/
+gitpkg master upstream
+# build the package
+cd ../deb-packages/torbirdy/
+dpkg-source -x torbirdy_$VERSION-1.dsc
+cd torbirdy-$VERSION
+DEBUILD_DPKG_BUILDPACKAGE_OPTS="-us -uc -I -i"
+DEBUILD_LINTIAN_OPTS="-i -I --show-overrides"
+debuild
+
+#### Now if you want - you can pretend you did the same steps as above ....
+git import-orig --filter=*.git --pristine-tar --upstream-version=$VERSION \
+  ../deb-packages/torbirdy/torbirdy_$VERSION.orig.tar.gz
+# build our deb and ignore anything not in git:
+git-buildpackage --git-ignore-new

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/torbirdy.git



More information about the Pkg-mozext-commits mailing list