r2489 - in people/goneri/update-pkg-games: . etc
Eddy Petrisor
eddyp-guest at alioth.debian.org
Thu Mar 8 18:51:53 CET 2007
Author: eddyp-guest
Date: 2007-03-08 17:51:53 +0000 (Thu, 08 Mar 2007)
New Revision: 2489
Modified:
people/goneri/update-pkg-games/etc/config
people/goneri/update-pkg-games/refresh.pl
Log:
- debrand refresh.pl (brand via etc/config)
- configure ADMINMAIL
- team mail is now configurable
- fixed inconsystencies in html page localization
- read ADMINMAIL from the configuration file (first draft, uses Shell::Source and brings in the need to add 'export' all over the place)
Modified: people/goneri/update-pkg-games/etc/config
===================================================================
--- people/goneri/update-pkg-games/etc/config 2007-03-08 14:32:28 UTC (rev 2488)
+++ people/goneri/update-pkg-games/etc/config 2007-03-08 17:51:53 UTC (rev 2489)
@@ -1,34 +1,36 @@
-IAM=$USER
+export IAM=$USER
# do not define this if you dont use externals
-#USEEXTERNALS='Yup Sir'
-[ -z "$ENTITY" ] && ENTITY=pkg-games
-[ -z "$ENTITYNAME" ] && ENTITYNAME='Debian Games Team'
-BUILDERADMIN='goneri at rulezlan.org'
+#export USEEXTERNALS='Yup Sir'
+[ -z "$ENTITY" ] && export ENTITY=pkg-games
+[ -z "$ENTITYNAME" ] && export ENTITYNAME='Debian Games Team'
+export TEAMEMAIL='pkg-games-devel at lists.alioth.debian.org'
+export BUILDERADMIN='goneri at rulezlan.org'
-UPDATELOCATION="/home/$IAM/update-$ENTITY"
+export UPDATELOCATION="/home/$IAM/update-$ENTITY"
# repo location
-SVN="svn://svn.debian.org/$ENTITY/packages/trunk/"
+export SVN="svn://svn.debian.org/$ENTITY/packages/trunk/"
# useful if a custom svn-buildpackage is used
#SVNBUILDPACKAGE="/home/$IAM/update-$ENTITY/bin/svn-buildpackage"
-SVNBUILDPACKAGE="/usr/bin/svn-buildpackage"
+export SVNBUILDPACKAGE="/usr/bin/svn-buildpackage"
-TMPDIR="/home/$IAM/tmp/update-$ENTITY/"
-CHECKSDIR="$UPDATELOCATION/checks/"
+export TMPDIR="/home/$IAM/tmp/update-$ENTITY/"
+export CHECKSDIR="$UPDATELOCATION/checks/"
-HTTPDIR="/home/$IAM/public_html/$ENTITY"
-HTTPRESULT="$HTTPDIR/debian"
-HTTPLOG="$HTTPDIR/log"
+export HTTPDIR="/home/$IAM/public_html/$ENTITY"
+export HTTPRESULT="$HTTPDIR/debian"
+export HTTPLOG="$HTTPDIR/log"
-LOGDIR="$UPDATELOCATION/log"
+export LOGDIR="$UPDATELOCATION/log"
-PBUILDER="sudo /usr/sbin/pbuilder"
-PDEBUILD="sudo /usr/bin/pdebuild"
-PBUILDERRC="$UPDATELOCATION/etc/pbuilderrc"
+export PBUILDER="sudo /usr/sbin/pbuilder"
+export PDEBUILD="sudo /usr/bin/pdebuild"
+export PBUILDERRC="$UPDATELOCATION/etc/pbuilderrc"
#do not stop building the package is SVN didn't change (0/1)
-FORCE_BUILD=0
+export FORCE_BUILD=0
# any params you might need to pass to pbuilder; recommended for overrides
-BUILDEREXTRAPARAMS="--svn-override=origDir=http://pkg-games.alioth.debian.org/tarballs"
+#BUILDEREXTRAPARAMS="--svn-override=origDir=http://pkg-games.alioth.debian.org/tarballs"
+export BUILDEREXTRAPARAMS="--svn-noninteractive"
Modified: people/goneri/update-pkg-games/refresh.pl
===================================================================
--- people/goneri/update-pkg-games/refresh.pl 2007-03-08 14:32:28 UTC (rev 2488)
+++ people/goneri/update-pkg-games/refresh.pl 2007-03-08 17:51:53 UTC (rev 2489)
@@ -9,6 +9,13 @@
use warnings;
use strict;
+# just import the configuration here, too
+use Shell::Source;
+my $shell = Shell::Source->new(shell => "sh", file => "etc/config");
+$shell->inherit;
+
+#exit 0;
+
my $green = "#6be053";
my $yellow = "#f7e583";
my $red = "#e74a4a";
@@ -20,10 +27,10 @@
# Configuration
my $destcharset = 'ISO-8859-1';
-my @teams_email = ('pkg-games-devel at lists.alioth.debian.org');
-my $html_output_dir = "/home/goneri/public_html/pkg-games/html/";
-my $local_builddir = "/home/goneri/public_html/pkg-games";
-my $remote_builddir = "/~goneri/pkg-games/";
+my @teams_email = ("$ENV{TEAMEMAIL}");
+my $html_output_dir = "$ENV{HTTPDIR}";
+my $local_builddir = "$ENV{HTTPDIR}";
+my $remote_builddir = "/~$ENV{IAM}/$ENV{ENTITY}";
sub showBugs {
@@ -119,16 +126,16 @@
sub create_statuspage {
- # still durty
+ # still dirty
my $email = shift;
open PAGE, ">$html_output_dir/$email.html" or die "can't open $html_output_dir/$email.html file: $!";;
print PAGE "<html><head>
- <title>Debian Games Team : $maintainers->{name_by_email}->{$email}</title>
+ <title>$ENV{ENTITYNAME} : $maintainers->{name_by_email}->{$email}</title>
</header>
<body>";
print PAGE "<table border=1>";
- print PAGE "<tr><th>Package</th><th>Last check (min)</th><th>Build</th><th>Upload Request</th><th>Lintian</th><th>Linda</th><th>Bugs</th><th>Debian Games Policy</th></tr>\n";
+ print PAGE "<tr><th>Package</th><th>Last check (min)</th><th>Build</th><th>Upload Request</th><th>Lintian</th><th>Linda</th><th>Bugs</th><th>$ENV{ENTITYNAME} Policy</th></tr>\n";
@@ -163,8 +170,8 @@
$linda = (@lindaerrs)?"<a href=\"$remote_builddir/log/$pkg/linda.log\">".int (@lindaerrs)."</a>":'';
my @pkggamespolicyerrs;
- @pkggamespolicyerrs = <DGP> if (open DGP,'<'."$remote_builddir/log/".$pkg."/pkg-games-policy.log");
- $pkggamespolicy = (@pkggamespolicyerrs)?"<a href=\"$remote_builddir/log/$pkg/pkg-games-policy.log\">".int (@pkggamespolicyerrs)."</a>":'';
+ @pkggamespolicyerrs = <DGP> if (open DGP,'<'."$remote_builddir/log/".$pkg."/$ENV{ENTITY}-policy.log");
+ $pkggamespolicy = (@pkggamespolicyerrs)?"<a href=\"$remote_builddir/log/$pkg/$ENV{ENTITY}-policy.log\">".int (@pkggamespolicyerrs)."</a>":'';
my $bugs = showBugs($pkg);
my $ur = (exists &uploadrequest()->{$pkg})?'Yes':'';
@@ -223,14 +230,14 @@
open PAGE, ">$html_output_dir/index.html" or die "can't open $html_output_dir/index.html file: $!";
print PAGE "<html><head>
- <title>Debian Games Team : Maintainers list</title>
+ <title>$ENV{ENTITYNAME} : Maintainers list</title>
</header>
<body>";
print PAGE "<h2>Teams</h2>\n";
print PAGE "<ul>";
foreach my $email (sort @t) {
- print PAGE "<li><a href=\"$remote_builddir/html/$email.html\">$maintainers->{name_by_email}->{$email}</a></li>";
+ print PAGE "<li><a href=\"$remote_builddir/$email.html\">$maintainers->{name_by_email}->{$email}</a></li>";
}
print PAGE "</ul>";
@@ -238,7 +245,7 @@
print PAGE "<h2>Maintainers</h2>\n";
print PAGE "<ul>";
foreach my $email (sort @m) {
- print PAGE "<li><a href=\"$remote_builddir/html/$email.html\">$maintainers->{name_by_email}->{$email}</a></li>";
+ print PAGE "<li><a href=\"$remote_builddir/$email.html\">$maintainers->{name_by_email}->{$email}</a></li>";
}
print PAGE "</ul>";
More information about the Pkg-games-commits
mailing list