--- /dev/null
+#!/usr/bin/env perl
+use strict;
+use warnings FATAL => 'all';
+use ExtUtils::Manifest qw(filecheck maniread maniskip manicheck mkmanifest);
+
+{
+ local $ExtUtils::Manifest::Quiet = 1;
+ my $manimiss = ! -e 'MANIFEST';
+ if (-e 'MANIFEST') {
+ my @extra = manicheck;
+ if (@extra) {
+ die "Files in MANIFEST are missing from file system:\n"
+ . join('', map " $_\n", @extra);
+ }
+
+ my $read = maniread;
+ my $skip = maniskip;
+
+ my @missing = manicheck;
+ my @remove = grep $skip->($_), sort keys %$read;
+
+ exit 0
+ if !(@missing || @remove);
+ }
+}
+
+warn "Updating MANIFEST:\n";
+mkmanifest;
+warn "Go check it and retry.\n";
+exit 1;
die "Tag v$version already exists!";
}
-for (scalar `"$make" manifest 2>&1 >$null`) {
- $_ && die "$make manifest changed:\n$_ Go check it and retry";
-}
-
for (scalar `git status`) {
/^(?:# )?On branch \Q$branch\E/ || die "Not on $branch. EEEK";
/Your branch is behind|Your branch and .*? have diverged/ && die "Not synced with upstream";
my $phony_targets = join ' ', qw(
preflight
check-version
+ check-manifest
releasetest
release
readmefile
(map "$_ = $vars{$_}\n", sort keys %vars),
<<'END',
-preflight: check-version
+preflight: check-version check-manifest
$(ABSPERLRUN) Distar/helpers/preflight $(VERSION) --changelog=$(CHANGELOG) --branch=$(BRANCH)
check-version:
$(ABSPERLRUN) Distar/helpers/check-version $(VERSION) $(TO_INST_PM) $(EXE_FILES)
+check-manifest:
+ $(ABSPERLRUN) Distar/helpers/check-manifest
releasetest:
$(MAKE) disttest RELEASE_TESTING=1 PASTHRU="$(PASTHRU) TEST_FILES=\"$(TEST_FILES)\""
release: preflight releasetest