[Pkg-ocaml-maint-commits] [SCM] dh-ocaml packaging branch, master, updated. debian/0.4-7-gd1b1bf8

Stephane Glondu steph at glondu.net
Mon Feb 23 20:16:36 UTC 2009


The following commit has been merged in the master branch:
commit 1120904dfa41de6ba89d52eca61436dd7874c40d
Author: Stephane Glondu <steph at glondu.net>
Date:   Mon Feb 23 21:10:23 2009 +0100

    Add ocaml-pkg-update-uploaders (Closes: #516764)
    
    This script updates debian/control with the last contributors using
    debian/changelog.

diff --git a/debian/install b/debian/install
index 3dbb3cd..f0fd90b 100644
--- a/debian/install
+++ b/debian/install
@@ -1,3 +1,4 @@
 cdbs/1                  usr/share/cdbs
 share/*                 usr/share/ocaml
-debhelper/dh_ocaml      usr/bin/
+debhelper/dh_ocaml      usr/bin
+tools/*                 usr/bin
diff --git a/share/ocaml-pkg-team b/share/ocaml-pkg-team
new file mode 100644
index 0000000..1ebf969
--- /dev/null
+++ b/share/ocaml-pkg-team
@@ -0,0 +1,26 @@
+Dimitri Ara <debian at mutu.net>
+Enrico Tassi <gareuselesinge at debian.org>
+Enrico Zini <enrico at debian.org>
+Eric Cooper <ecc at cmu.edu>
+Erik de Castro Lopo <erikd at mega-nerd.com>
+Georg Neis <gn at oglaroon.de>
+Guido Guenther <agx at sigxcpu.org>
+Guido Günther <agx at sigxcpu.org>
+John Skaller <skaller at users.sf.net>
+Jonathan Roudiere <jonathan.roudiere at lipn.univ-paris13.fr>
+Marco Sinhoreli <msinhore at gmail.com>
+Martin Pitt <mpitt at debian.org>
+Mehdi Dogguy <dogguy at pps.jussieu.fr>
+Mike Furr <mfurr at debian.org>
+Oguz Berke Durak <berke-dev at ouvaton.org>
+Pietro Abate <pietro.abate at pps.jussieu.fr>
+Ralf Treinen <treinen at debian.org>
+Remi Vanicat <vanicat at debian.org>
+Richard W.M. Jones <rich at annexia.org>
+Romain Beauxis <toots at rastageeks.org>
+Samuel Mimram <smimram at debian.org>
+Stefano Zacchiroli <zack at debian.org>
+Steffen Joeris <white at debian.org>
+Stephane Glondu <steph at glondu.net>
+Sven Luther <luther at debian.org>
+Sylvain Le Gall <gildor at debian.org>
diff --git a/tools/ocaml-pkg-update-uploaders b/tools/ocaml-pkg-update-uploaders
new file mode 100755
index 0000000..d0c25a9
--- /dev/null
+++ b/tools/ocaml-pkg-update-uploaders
@@ -0,0 +1,73 @@
+#!/usr/bin/perl -w
+#
+# Description: generating .install files for ocaml binary packages
+#
+# Copyright © 2009 Stéphane Glondu <steph at glondu.net>
+#           © 2009 Mehdi Dogguy <dogguy at pps.jussieu.fr>
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301 USA.
+#
+
+# Number of changelog entries to look at
+my $limit = $ENV{LAST_ENTRIES} || 5;
+my $team = $ENV{OCAML_TEAM} || "/usr/share/ocaml/ocaml-pkg-team";
+my $control = $ENV{DEBIAN_CONTROL} || "debian/control";
+
+# Retreive team members
+my %members;
+open(TEAM, "< $team") || die("cannot find $team\n");
+while (<TEAM>) {
+    if (/^(.*) <(.*)>$/) {
+        $members{$1} = $2;
+    }
+}
+close TEAM;
+
+# Retreive last contributors
+my %uploaders;
+my $nb_uploads = 0;
+open(CHANGELOG, "< debian/changelog") || die("cannot find debian/changelog\n");
+while (<CHANGELOG>) {
+    last if ($nb_uploads >= $limit);
+    if (/\[ (.*) \]/) {
+        $uploaders{" $1 <$members{$1}>"} = 0;
+    } elsif (/^ -- (.*) </) {
+        $uploaders{" $1 <$members{$1}>"} = 0;
+        $nb_uploads++;
+    }
+}
+close CHANGELOG;
+
+# Update control
+open(CONTROL, "< $control") || die("cannot find $control\n");
+open(CONTROLNEW, "> ${control}.new");
+while (<CONTROL>) {
+    if (/^Uploaders:/) {
+        print CONTROLNEW "Uploaders:\n";
+        print CONTROLNEW join(",\n", sort(keys(%uploaders))), "\n";
+        # Skip remaining Uploaders
+        while (<CONTROL>) {
+            if (!/^ /) {
+                print CONTROLNEW; last;
+            }
+        }
+    } else {
+        print CONTROLNEW;
+    }
+}
+close CONTROLNEW;
+close CONTROL;
+rename("${control}.new", "$control");

-- 
dh-ocaml packaging



More information about the Pkg-ocaml-maint-commits mailing list