r42508 - /scripts/qa/packagecheck.pl
jeremiah-guest at users.alioth.debian.org
jeremiah-guest at users.alioth.debian.org
Sat Aug 22 22:10:15 UTC 2009
Author: jeremiah-guest
Date: Sat Aug 22 22:10:07 2009
New Revision: 42508
URL: http://svn.debian.org/wsvn/?sc=1&rev=42508
Log:
Still working on packagecheck. Progress is slow. :(
Modified:
scripts/qa/packagecheck.pl
Modified: scripts/qa/packagecheck.pl
URL: http://svn.debian.org/wsvn/scripts/qa/packagecheck.pl?rev=42508&op=diff
==============================================================================
--- scripts/qa/packagecheck.pl (original)
+++ scripts/qa/packagecheck.pl Sat Aug 22 22:10:07 2009
@@ -64,17 +64,37 @@
pod2usage(1) if $help;
pod2usage(1) if not $ARGV[0];
-# Process options
+=over 8
+
+=item sanity_check
+
+Checks to see if we are in a directory. (Takes a directory as an arg.)
+
+=cut
sub sanity_check {
my $dir = shift;
if (not -d $dir) {
die "Cannot find working directory $dir: $!";
}
-
}
-if ($current) {
+=over 8
+
+=item testvcs
+
+Test for presence of Vcs fields in control file.
+
+=cut
+
+sub testvcs {
+ my $dir = shift;
+ print "Dir is $dir\n";
+}
+
+
+# Process options
+if ($current) { # check for checked out packages in the current dir
my $cwd = cwd();
sanity_check($cwd);
@@ -87,10 +107,12 @@
my @svnmods = capture("svn st $cwd");
if ($svnmods[-1]) {
print map { $_ } @svnmods;
- }
+ die "Exiting. $cwd appears to have uncommitted modifications.\n";
+ }
else {
print "It appears dir is clean.\n";
}
+ testvcs($cwd)
}
More information about the Pkg-perl-cvs-commits
mailing list