Git-buildpackage
From Wikitech
(Difference between revisions)
(→Experiments) |
(→Experiments) |
||
| Line 45: | Line 45: | ||
+ | + | ||
</pre> | </pre> | ||
| − | * Cool, but not quite what I need. | + | * Cool, but not quite what I need. There was no commit, so let's simply revert that, and try again after reading the git-dch manual: |
| + | $ git checkout debian/changelog | ||
| + | $ git-dch --snapshot -N 2.7.6+2.7.7rc2 --git-author | ||
| + | <pre> | ||
| + | $ git diff | ||
| + | diff --git a/debian/changelog b/debian/changelog | ||
| + | index 796b61e..06a9cac 100644 | ||
| + | --- a/debian/changelog | ||
| + | +++ b/debian/changelog | ||
| + | @@ -1,3 +1,11 @@ | ||
| + | +puppet (2.7.6+2.7.7rc2~1.gbp484735) UNRELEASED; urgency=low | ||
| + | + | ||
| + | + ** SNAPSHOT build @48473567008ad82cdb0d0a5654dffe7c868fad91 ** | ||
| + | + | ||
| + | + * Imported Upstream version 2.7.7rc2 | ||
| + | + | ||
| + | + -- Mark Bergsma <mark@wikimedia.org> Wed, 23 Nov 2011 14:23:22 +0000 | ||
| + | + | ||
| + | </pre> | ||
[[Category:Ubuntu]] [[Category:Package management]] | [[Category:Ubuntu]] [[Category:Package management]] | ||
Revision as of 14:21, 23 November 2011
(To be written up once experimentation is done.)
Experiments
Mark is experimenting with building puppet using git-buildpackage, in labs.
On i-00000080:
- The debian puppet package git repository was cloned into ~/git/debs/puppet:
$ cd ~/git/debs/ $ git clone git://git.debian.org/git/pkg-puppet/puppet.git
- Package build was attempted with git-buildpackage --git-ignore-new --git-pristine-tar
- Signing the package failed, as the Debian maintainer's secret key is not available.
- Package build was attempted without signing:
$ git-buildpackage --git-ignore-new --git-pristine-tar -us -uc
- This worked. We ended up with built packages in ~/git/debs, and a dirty git working dir.
- The git working directory was made clean again, and another build was attempted using
$ git-buildpackage --git-ignore-new --git-pristine-tar -us -uc --git-export-dir=/var/tmp/build-area/puppet
- This worked as well. Packages were being built, and the git working dir remained clean. Packages ended up in the build dir.
- The debian git dir only had version 2.7.6, but we want 2.7.7rc2. So I tried importing the dev release with
$ git-import-orig /tmp/puppet-2.7.7rc2.tar.gz
- This failed, as there was no local upstream branch in the cloned git repository yet. Ok, so let's create it from origin/upstream:
$ git branch upstream origin/upstream
- Now the import worked. But commits were made, with the default git name/mail address. Do set it:
$ git config --global user.name "Your Name" $ git config --global user.email you@example.com
- Try another build.
$ git-buildpackage --git-ignore-new --git-pristine-tar -us -uc --git-export-dir=/var/tmp/build-area/puppet
- Oops. This used version 2.7.6. But, the git-buildpackage manual says changing the changelog itself all the time isn't a good idea. Let's try git-dch:
$ git-dch --snapshot Changelog has been prepared for snapshot #1 at 48473567008ad82cdb0d0a5654dffe7c868fad91
$ git diff diff --git a/debian/changelog b/debian/changelog index 796b61e..f6da810 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +puppet (2.7.6-1ubuntu1~1.gbp484735) UNRELEASED; urgency=low + + ** SNAPSHOT build @48473567008ad82cdb0d0a5654dffe7c868fad91 ** + + * Imported Upstream version 2.7.7rc2 + + -- Mark Bergsma <mark@i-00000080.pmtpa.wmflabs> Wed, 23 Nov 2011 14:06:45 +0000 +
- Cool, but not quite what I need. There was no commit, so let's simply revert that, and try again after reading the git-dch manual:
$ git checkout debian/changelog $ git-dch --snapshot -N 2.7.6+2.7.7rc2 --git-author
$ git diff diff --git a/debian/changelog b/debian/changelog index 796b61e..06a9cac 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +puppet (2.7.6+2.7.7rc2~1.gbp484735) UNRELEASED; urgency=low + + ** SNAPSHOT build @48473567008ad82cdb0d0a5654dffe7c868fad91 ** + + * Imported Upstream version 2.7.7rc2 + + -- Mark Bergsma <mark@wikimedia.org> Wed, 23 Nov 2011 14:23:22 +0000 +