summaryrefslogtreecommitdiff
path: root/Debian/Debhelper/Dh_Getopt.pm
diff options
context:
space:
mode:
authorModestas Vainius <modestas@vainius.eu>2009-03-23 02:23:17 +0200
committerJoey Hess <joey@gnu.kitenet.net>2009-03-23 14:59:13 -0400
commit66c68aa531bc5a1739be40c25483f036022de7a1 (patch)
tree4eb57b19e070a427bdffdf94a7308c45c62aa8b8 /Debian/Debhelper/Dh_Getopt.pm
parentce53a5276c9f3a388dce10f442c3c1659e3bccdb (diff)
Add a global --remaining-packages option.
Add a global --remaining-packages option which allows to skip the command on the packages which it has already been run on (i.e. if the command helper is already present in the package debhelper log). Signed-off-by: Modestas Vainius <modestas@vainius.eu>
Diffstat (limited to 'Debian/Debhelper/Dh_Getopt.pm')
-rw-r--r--Debian/Debhelper/Dh_Getopt.pm6
1 files changed, 6 insertions, 0 deletions
diff --git a/Debian/Debhelper/Dh_Getopt.pm b/Debian/Debhelper/Dh_Getopt.pm
index ef94e940..5585a54c 100644
--- a/Debian/Debhelper/Dh_Getopt.pm
+++ b/Debian/Debhelper/Dh_Getopt.pm
@@ -91,6 +91,8 @@ sub getoptions {
"N=s" => \&ExcludePackage,
"no-package=s" => \&ExcludePackage,
+ "remaining-packages" => \$dh{EXCLUDE_LOGGED},
+
"dbg-package=s" => \&AddDebugPackage,
"s" => \&AddPackage,
@@ -222,6 +224,10 @@ sub parseopts {
my $package;
my %packages_seen;
foreach $package (@{$dh{DOPACKAGES}}) {
+ if (defined($dh{EXCLUDE_LOGGED}) &&
+ grep { $_ eq basename($0) } load_log($package)) {
+ $exclude_package{$package}=1;
+ }
if (! $exclude_package{$package}) {
if (! exists $packages_seen{$package}) {
$packages_seen{$package}=1;