summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRuss Allbery <rra@cpan.org>2022-01-16 22:43:50 -0800
committerRuss Allbery <rra@cpan.org>2022-01-16 22:43:50 -0800
commitc6169738fb85c40d15c2a24bcfe2894c2da1688f (patch)
treea4a6e898fc84b3d54c176ea4f14fc53014782376
parentc9fd563f8882463c7af8a89e38bfbaf10e5e7c4f (diff)
Always regenerate the *.tar.xz file
Ensure docknot dist always regenerates the *.tar.xz file if necessary, rather than reusing one left over from a previous build of the same version.
-rw-r--r--Changes4
-rw-r--r--lib/App/DocKnot/Dist.pm8
-rwxr-xr-xt/dist/basic.t2
3 files changed, 9 insertions, 5 deletions
diff --git a/Changes b/Changes
index f0b26ee..bb6ec69 100644
--- a/Changes
+++ b/Changes
@@ -18,6 +18,10 @@
pass. This ensurse the output files are seen when spinning the tree
into the output directory.
+ - Ensure docknot dist always regenerates the *.tar.xz file if necessary,
+ rather than reusing one left over from a previous build of the same
+ version.
+
- Always recreate GnuPG signatures when generating distribution tarballs
in docknot dist.
diff --git a/lib/App/DocKnot/Dist.pm b/lib/App/DocKnot/Dist.pm
index 382a41c..fcdeafd 100644
--- a/lib/App/DocKnot/Dist.pm
+++ b/lib/App/DocKnot/Dist.pm
@@ -403,16 +403,16 @@ sub make_distribution {
systemx($command_ref->@*);
}
- # Move the generated tarball to the parent directory.
+ # Generate additional compression formats if needed.
+ $self->_generate_compression_formats(path(q{.}), $prefix);
+
+ # Move the generated tarballs to the parent directory.
$self->_move_tarballs(path(q{.}), $prefix, $self->{distdir});
# Remove the working tree.
chdir($self->{distdir});
$workdir->remove_tree();
- # Generate additional compression formats if needed.
- $self->_generate_compression_formats($self->{distdir}, $prefix);
-
# Check the distribution for any missing files. If there are any, report
# them and then fail with an error.
my $tarball = $self->_find_gzip_tarball($self->{distdir}, $prefix);
diff --git a/t/dist/basic.t b/t/dist/basic.t
index 5b72cb9..3796a81 100755
--- a/t/dist/basic.t
+++ b/t/dist/basic.t
@@ -120,7 +120,7 @@ ok($distdir->child('Empty-1.00.tar.xz.asc')->exists(), 'xz signature');
is(
"some signature\n",
$distdir->child('Empty-1.00.tar.gz.asc')->slurp_utf8(),
- 'fake-gpg was run'
+ 'fake-gpg was run',
);
# If we add a new file to the source tree and run make_distribution() again,