[pkg-kolab] r1233 - /
mparent-guest at alioth.debian.org
mparent-guest at alioth.debian.org
Sat Mar 7 18:09:01 UTC 2009
Author: mparent-guest
Date: 2009-03-07 18:09:01 +0000 (Sat, 07 Mar 2009)
New Revision: 1233
Added:
pkg-kolab_toolbox
Log:
Commit toolbox
Added: pkg-kolab_toolbox
===================================================================
--- pkg-kolab_toolbox (rev 0)
+++ pkg-kolab_toolbox 2009-03-07 18:09:01 UTC (rev 1233)
@@ -0,0 +1,136 @@
+#!/usr/bin/perl
+
+=head1 NAME
+
+pkg-kolab_toolbox - Debian toolbox for kolab packaging
+
+=head1 SYNOPSIS
+
+B<pkg-kolab_toolbox> [options] argument
+
+=head1 ARGUMENTS
+
+=over 8
+
+=item I<build>
+
+Build all
+
+=back
+
+=head1 OPTIONS
+
+=over 8
+
+=item B<--help>
+
+Print a brief help message and exits.
+
+=item B<--man>
+
+Prints the manual page and exits.
+
+=item B<--verbose>
+
+Increase verbosity.
+
+=item B<--branch>
+
+Change branch (default: current)
+
+=back
+
+=head1 COPYRIGHT AND AUTHORS
+
+Copyright (c) 2008 Mathieu Parent <math.parent at gmail.com>
+
+=head1 LICENSE
+
+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 can view the GNU General Public License, online, at the GNU
+Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
+
+=cut
+
+use strict;
+
+use Getopt::Long;
+use Pod::Usage;
+use File::Path;
+
+my $basedir = '/home/mathieu/apps/pkg-kolab';
+
+my %branches = (
+ 'current' => {
+ 'libkolab-perl' => 'branches/2.2.1',
+ #'kolabconf' => 'trunk',
+ 'kolabd' => 'branches/2.2.1',
+ #'php-kolab' => 'trunk',
+ #'kolab-freebusy' => 'trunk',
+ #'kolab-filter' => 'trunk',
+ 'kolab-webadmin' => 'branches/2.2.1',
+
+ 'pear-horde-channel' => 'trunk',
+ 'php-kolab-filter' => 'trunk',
+ 'php-kolab-format' => 'trunk',
+ 'php-kolab-freebusy' => 'trunk',
+ 'php-kolab-server' => 'trunk',
+ 'php-kolab-storage' => 'trunk',
+
+ 'kolab-webclient' => 'trunk',
+ },
+);
+
+my $o_help = 0;
+my $o_man = 0;
+my $o_verbose = '';
+my $o_branch = 'current';
+
+Getopt::Long::Configure('permute');
+my $result = GetOptions(
+ 'help|?' => \$o_help,
+ 'man' => \$o_man,
+ 'verbose!' => \$o_verbose,
+ '<>' => \&process,
+ 'branch=s' => \$o_branch,
+ ) or pod2usage(2);
+
+pod2usage(-exitstatus => 0, -verbose => 2) if $o_man;
+pod2usage(-exitstatus => 0, -verbose => 1);
+
+sub info {
+ my $text = shift;
+ my $level = shift || 0;
+ print "$text\n" if $level >= $o_verbose;
+}
+
+sub process {
+ my $action = shift;
+ info("Empty branch `$o_branch'") if(!defined($branches{$o_branch}));
+ if($action eq 'build') {
+ for my $package ( keys %{ $branches{$o_branch} } ) {
+ my $branch = $branches{$o_branch}{$package};
+ info("================================");
+ info($package);
+ info("================================");
+ rmtree("$basedir/$package/build-area");
+ chdir "$basedir/$package/$branch";
+ system("svn-buildpackage --svn-ignore-new > /dev/null 2> /dev/null");
+ chdir "$basedir/$package/build-area";
+ system("lintian --display-info --pedantic --color always *.changes");
+ }
+ } else {
+ pod2usage(-exitstatus => 0, -verbose => 1, -message => "Invalid action `$action'");
+ }
+ exit 0;
+}
+
Property changes on: pkg-kolab_toolbox
___________________________________________________________________
Name: svn:executable
+ *
More information about the pkg-kolab-devel
mailing list