Author: plessy
Date: 2011-03-21 09:46:42 +0000 (Mon, 21 Mar 2011)
New Revision: 6339
Modified:
trunk/community/website/docs/policy.xml
Log:
Moved more tips to the top.
Modified: trunk/community/website/docs/policy.xml
===================================================================
--- trunk/community/website/docs/policy.xml 2011-03-21 09:40:16 UTC (rev
6338)
+++ trunk/community/website/docs/policy.xml 2011-03-21 09:46:42 UTC (rev
6339)
@@ -192,21 +192,21 @@
</sect2>
<sect2 id="subversion-tips">
<title>Subversion tips</title>
- <para>
+ <para id="svn-buildpackage-aliases">
Suggested aliases for
<command>svn-buildpackage</command>:<programlisting>
alias <command>svn-b</command>='svn-buildpackage -us -uc -rfakeroot
--svn-ignore'
alias <command>svn-br</command>='svn-b --svn-dont-purge --svn-reuse'
alias <command>svn-bt</command>='svn-buildpackage --svn-tag
-rfakeroot'</programlisting>
</para>
- <para>
+ <para id="download-upstream-source">
To download the upstream sources (if there is a
<filename>debian/watch</filename> file):
<code><command>echo
"origDir=.." >> .svn/deb-layout
&& uscan
--force-download</command></code>.
Alternatively, you can try
<code><command>debian/rules
get-orig-source</command></code>.
</para>
- <para>
+ <para id="svn-write-access">
If you're a Debian developer or a member of the
Debian Med group on
Alioth, you can commit your changes:
<command>svn commit</command> (also
<command>svn ci</command>). Otherwise, you can
ask to be added to the
@@ -215,7 +215,7 @@
url="mailto:[email protected]">mailing list</ulink>
(<command>gzip -9</command> it, if it's too
large).
</para>
- <para>
+ <para id="svn-tag-release">
It may happen that a package version has been
uploaded to Debian
repositories, and you forgot to tag the last
build with
<command>svn-buildpackage --svn-tag</command>.
You can tag this package
@@ -348,12 +348,19 @@
<literal>master</literal> branch unless it is
somehow related to other
branches), so be sure to also do a run with
<option>--all</option>, and one with <option>--tags</option> if you created new
tags.
</para>
+ <para id="git-tag-release">
+ To tag a release:
+ <code><command>git tag</command>
<option>debian/x.y-z</option></code>.
+ You can also easily retroactively make tags:
+ <code><command>git tag</command>
<option>debian/x.y-z</option> <option><commit hash></option></code>.
+ Remember to <code><command>git push
--tags</command></code>.
+ </para>
<para id="git-layout-variants">
In particular for Git repositories that are not
stored in Alioth, the
layout can differ from
<command>git-buildpackage</command> conventions.
In that case, look for instance for a branch
called <literal>debian</literal>.
</para>
- <para>
+ <para id="git-debian-version-from-commit">
If upstream manages his sources with Git, the
following makefile
script can help producing a version number when
no Git tag is
available:<programlisting>
@@ -367,7 +374,31 @@
get-orig-source:
git archive --format=tar $(SHA1) | gzip -9 > ../$(ORIG)</programlisting>
- </para>
+ </para>
+ <para>
+ To make <command>git-buildpackage</command>
builds the package with a
+ chroot, you can add the folowwing to the
configuration file <filename>~/.gbp.conf</filename> or
<filename>debian/gbp.conf</filename>:<programlisting>
+[DEFAULT]
+builder = ~/bin/git-pbuilder
+cleaner = fakeroot debian/rules clean
+pristine-tar = True
+
+[git-buildpackage]
+# use this for more svn-buildpackage like behaviour:
+export-dir = ../build-area/
+tarball-dir = ../tarballs/</programlisting>
+ With this configuration file you're specifying
that
+ <command>git-buildpackage</command> will use
+ <filename>~/bin/git-pbuilder</filename> as the
builder script. This is
+ an example script you can use:<programlisting>
+#!/bin/sh
+set -e
+
+pdebuild --pbuilder cowbuilder --debbuildopts "-i\.git -I.git $*"
+rm ../*_source.changes</programlisting>
+ This will build the package inside the default
cowbuilder chroot, while
+ passing any more parameters directly do
<command>dpkg-buildpackage</command>.
+ </para>
</sect2>
<sect2 id="subversion-to-git">
@@ -589,72 +620,13 @@
</para>
</sect3>
</sect2>
- <sect2 id="building-and-tagging">
- <title>Building and tagging the packages</title>
- <sect3 id="building">
- <title>Building the packages</title>
- <sect4 id="building-git">
- <title>Git</title>
- <para>You should use <command>git-buildpackage</command> to
build the
- packages with git. Be sure to run it from the
<quote>master</quote>
- branch.</para>
- <para>Unfortunately, by default
<command>git-buildpackage</command>
- builds the package without using any chroot (the same as
- <command>svn-buildpackage</command>), but it's configurable to
run
- it inside a chroot.</para>
- <para>You can use this configuration file,
<filename>~/.gbp.conf</filename>:</para>
- <blockquote>
- <programlisting>[DEFAULT]
-builder = ~/bin/git-pbuilder
-cleaner = fakeroot debian/rules clean
-pristine-tar = True
-
-[git-buildpackage]
-# use this for more svn-buildpackage like behaviour:
-export-dir = ../build-area/
-tarball-dir = ../tarballs/</programlisting>
- </blockquote>
- <para>With this configuration file you're specifying that
- <command>git-buildpackage</command> will use
<filename>~/bin/git-pbuilder</filename>
- as the builder script. This is an example script you can
use:</para>
- <blockquote>
- <programlisting>#!/bin/sh
-set -e
-
-pdebuild --pbuilder cowbuilder --debbuildopts "-i\.git -I.git $*"
-rm ../*_source.changes</programlisting>
- </blockquote>
- <para>This will build the package inside the default
cowbuilder chroot, while
- passing any more parameters directly do
<command>dpkg-buildpackage</command>.</para>
- </sect4>
- </sect3>
- <sect3 id="tagging">
- <title>Tagging packages</title>
- <sect4 id="tagging-git">
- <title>Git</title>
- <para>Tagging a release with git is pretty
straightforward:</para>
- <blockquote>
- <para><userinput>
- <command>git tag</command>
- <option>tagname</option>
- </userinput></para>
- </blockquote>
- <para>The tag names usually follow the scheme
<quote>debian/x.y-z</quote>,
- this will ensure compatibility with other tools as well
(like
- <command>git import-dsc</command>).</para>
- <para>You can also easily retroactively make tags:</para>
- <blockquote>
- <para><userinput>
- <command>git checkout</command>
- <option><commit hash></option>
- </userinput></para>
- </blockquote>
- <para>You're now at the point in history when you released
the package.
- Just tag it as you would normally do.</para>
- <para>After tagging, be sure to <command>git push
--tags</command>, so that
- other people can benefit from it too.</para>
- </sect4>
- </sect3>
+ <sect2 id="building-and-tagging">
+ <title>Building and tagging the packages</title>
+ <para>
+ We prefer that uploaded packages are built in a
chroot, to provide
+ similar build environment to the whole team.
After upload, please <link linkend="vcs-tags">tag</link>
+ the <link
linkend="svn-tag-release">Suvbersion</link> or <link
linkend="git-tag-release">Git</link> repository.
+ </para>
</sect2>
<sect2 id="patches">
<title>Handling patches</title>
_______________________________________________
debian-med-commit mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/debian-med-commit