summaryrefslogtreecommitdiff
path: root/dh
diff options
context:
space:
mode:
authorNiels Thykier <niels@thykier.net>2018-09-13 19:45:08 +0000
committerNiels Thykier <niels@thykier.net>2018-09-14 18:54:22 +0000
commit50a57fe58d8c11c9aee936555b1ecda7200a8070 (patch)
tree35ebfc3cbd21e9d474ac13b02eff17b1a689e8ab /dh
parentb4d25f15292cba1f3781fb6c8747697897d4099b (diff)
downloaddebhelper-50a57fe58d8c11c9aee936555b1ecda7200a8070.tar.gz
dh: Add hidden ENV variable to test can_skip under --no-act
Signed-off-by: Niels Thykier <niels@thykier.net>
Diffstat (limited to 'dh')
-rwxr-xr-xdh4
1 files changed, 3 insertions, 1 deletions
diff --git a/dh b/dh
index 35ef157c..9b158ead 100755
--- a/dh
+++ b/dh
@@ -874,7 +874,7 @@ foreach my $i (0..$stoppoint) {
}
next unless @todo;
- next if can_skip($command, @todo) && ! $dh{NO_ACT};
+ next if can_skip($command, @todo);
# No need to run the command for any packages handled by the
# override targets.
@@ -1031,6 +1031,8 @@ my %skipinfo;
sub can_skip {
my ($command, @packages) = @_;
+ return 0 if $dh{NO_ACT} and not $ENV{DH_INTERNAL_TEST_CAN_SKIP};
+
return 0 if $unoptimizable_user_option ||
(exists $ENV{DH_OPTIONS} && length $ENV{DH_OPTIONS});