Support Maven's reproducible build feature for war repackaging
See gh-25571
This commit is contained in:
committed by
Andy Wilkinson
parent
9180220cf4
commit
3c0e236562
@@ -21,7 +21,6 @@ import java.io.IOException;
|
||||
import java.nio.file.attribute.FileTime;
|
||||
import java.util.jar.JarFile;
|
||||
|
||||
import org.springframework.boot.loader.tools.Layouts.War;
|
||||
import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
@@ -102,9 +101,6 @@ public class Repackager extends Packager {
|
||||
throws IOException {
|
||||
Assert.isTrue(destination != null && !destination.isDirectory(), "Invalid destination");
|
||||
Layout layout = getLayout(); // get layout early
|
||||
if (lastModifiedTime != null && layout instanceof War) {
|
||||
throw new IllegalStateException("Reproducible repackaging is not supported with war packaging");
|
||||
}
|
||||
destination = destination.getAbsoluteFile();
|
||||
File source = getSource();
|
||||
if (isAlreadyPackaged() && source.equals(destination)) {
|
||||
|
||||
Reference in New Issue
Block a user