Compare commits

..

No commits in common. "main" and "0.4.5" have entirely different histories.
main ... 0.4.5

12 changed files with 16 additions and 115 deletions

6
.idea/bld.xml generated
View file

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="BldConfiguration">
<events />
</component>
</project>

View file

@ -2,12 +2,11 @@
<library name="bld"> <library name="bld">
<CLASSES> <CLASSES>
<root url="file://$PROJECT_DIR$/lib/bld" /> <root url="file://$PROJECT_DIR$/lib/bld" />
<root url="jar://$USER_HOME$/.bld/dist/bld-2.0.1.jar!/" /> <root url="jar://$USER_HOME$/.bld/dist/bld-1.7.5.jar!/" />
</CLASSES> </CLASSES>
<JAVADOC /> <JAVADOC />
<SOURCES> <SOURCES>
<root url="file://$PROJECT_DIR$/lib/bld" /> <root url="jar://$USER_HOME$/.bld/dist/bld-1.7.5-sources.jar!/" />
<root url="jar://$USER_HOME$/.bld/dist/bld-2.0.1-sources.jar!/" />
</SOURCES> </SOURCES>
<excluded> <excluded>
<root url="jar://$PROJECT_DIR$/lib/bld/bld-wrapper.jar!/" /> <root url="jar://$PROJECT_DIR$/lib/bld/bld-wrapper.jar!/" />

View file

@ -2,16 +2,12 @@
<library name="compile"> <library name="compile">
<CLASSES> <CLASSES>
<root url="file://$PROJECT_DIR$/lib/compile" /> <root url="file://$PROJECT_DIR$/lib/compile" />
<root url="file://$PROJECT_DIR$/lib/provided" />
</CLASSES> </CLASSES>
<JAVADOC /> <JAVADOC />
<SOURCES> <SOURCES>
<root url="file://$PROJECT_DIR$/lib/compile" /> <root url="file://$PROJECT_DIR$/lib/compile" />
<root url="file://$PROJECT_DIR$/lib/provided" />
</SOURCES> </SOURCES>
<jarDirectory url="file://$PROJECT_DIR$/lib/compile" recursive="false" /> <jarDirectory url="file://$PROJECT_DIR$/lib/compile" recursive="false" />
<jarDirectory url="file://$PROJECT_DIR$/lib/compile" recursive="false" type="SOURCES" /> <jarDirectory url="file://$PROJECT_DIR$/lib/compile" recursive="false" type="SOURCES" />
<jarDirectory url="file://$PROJECT_DIR$/lib/provided" recursive="false" />
<jarDirectory url="file://$PROJECT_DIR$/lib/provided" recursive="false" type="SOURCES" />
</library> </library>
</component> </component>

View file

@ -2,7 +2,6 @@
<library name="runtime"> <library name="runtime">
<CLASSES> <CLASSES>
<root url="file://$PROJECT_DIR$/lib/runtime" /> <root url="file://$PROJECT_DIR$/lib/runtime" />
<root url="file://$PROJECT_DIR$/src/main/resources" />
</CLASSES> </CLASSES>
<JAVADOC /> <JAVADOC />
<SOURCES> <SOURCES>

View file

@ -2,16 +2,12 @@
<library name="test"> <library name="test">
<CLASSES> <CLASSES>
<root url="file://$PROJECT_DIR$/lib/test" /> <root url="file://$PROJECT_DIR$/lib/test" />
<root url="file://$PROJECT_DIR$/lib/provided" />
</CLASSES> </CLASSES>
<JAVADOC /> <JAVADOC />
<SOURCES> <SOURCES>
<root url="file://$PROJECT_DIR$/lib/test" /> <root url="file://$PROJECT_DIR$/lib/test" />
<root url="file://$PROJECT_DIR$/lib/provided" />
</SOURCES> </SOURCES>
<jarDirectory url="file://$PROJECT_DIR$/lib/provided" recursive="false" />
<jarDirectory url="file://$PROJECT_DIR$/lib/test" recursive="false" /> <jarDirectory url="file://$PROJECT_DIR$/lib/test" recursive="false" />
<jarDirectory url="file://$PROJECT_DIR$/lib/provided" recursive="false" type="SOURCES" />
<jarDirectory url="file://$PROJECT_DIR$/lib/test" recursive="false" type="SOURCES" /> <jarDirectory url="file://$PROJECT_DIR$/lib/test" recursive="false" type="SOURCES" />
</library> </library>
</component> </component>

View file

@ -7,7 +7,7 @@
], ],
"java.configuration.updateBuildConfiguration": "automatic", "java.configuration.updateBuildConfiguration": "automatic",
"java.project.referencedLibraries": [ "java.project.referencedLibraries": [
"${HOME}/.bld/dist/bld-2.0.1.jar", "${HOME}/.bld/dist/bld-1.7.5.jar",
"lib/compile/*.jar", "lib/compile/*.jar",
"lib/runtime/*.jar", "lib/runtime/*.jar",
"lib/test/*.jar" "lib/test/*.jar"

View file

@ -2,7 +2,6 @@
[![License](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![License](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Java](https://img.shields.io/badge/java-17%2B-blue)](https://www.oracle.com/java/technologies/javase/jdk17-archive-downloads.html) [![Java](https://img.shields.io/badge/java-17%2B-blue)](https://www.oracle.com/java/technologies/javase/jdk17-archive-downloads.html)
[![bld](https://img.shields.io/badge/2.0.1-FA9052?label=bld&labelColor=2392FF)](https://rife2.com/bld)
[![Release](https://flat.badgen.net/maven/v/metadata-url/https:/repo.rife2.com/releases/com/uwyn/rife2/bld-archive/maven-metadata.xml)](https://repo.rife2.com/#/releases/com/uwyn/rife2/bld-archive) [![Release](https://flat.badgen.net/maven/v/metadata-url/https:/repo.rife2.com/releases/com/uwyn/rife2/bld-archive/maven-metadata.xml)](https://repo.rife2.com/#/releases/com/uwyn/rife2/bld-archive)
[![GitHub CI](https://github.com/rife2/bld-archive/actions/workflows/bld.yml/badge.svg)](https://github.com/rife2/bld-archive/actions/workflows/bld.yml) [![GitHub CI](https://github.com/rife2/bld-archive/actions/workflows/bld.yml/badge.svg)](https://github.com/rife2/bld-archive/actions/workflows/bld.yml)

Binary file not shown.

View file

@ -3,4 +3,4 @@ bld.downloadExtensionSources=true
bld.extensions= bld.extensions=
bld.repositories=MAVEN_CENTRAL,RIFE2_RELEASES bld.repositories=MAVEN_CENTRAL,RIFE2_RELEASES
bld.downloadLocation= bld.downloadLocation=
bld.version=2.0.1 bld.version=1.7.5

View file

@ -1 +0,0 @@
bld.repo.github=https://maven.pkg.github.com/rife2/bld-archive

View file

@ -19,7 +19,7 @@ public class ArchiveBuild extends Project {
public ArchiveBuild() { public ArchiveBuild() {
pkg = "rife.bld.extension"; pkg = "rife.bld.extension";
name = "Archive"; name = "Archive";
version = version(0,5,0); version = version(0,4,5);
archiveBaseName = "bld-archive"; archiveBaseName = "bld-archive";
javaRelease = 17; javaRelease = 17;
@ -28,11 +28,11 @@ public class ArchiveBuild extends Project {
repositories = List.of(MAVEN_CENTRAL, RIFE2_RELEASES); repositories = List.of(MAVEN_CENTRAL, RIFE2_RELEASES);
scope(compile) scope(compile)
.include(dependency("com.uwyn.rife2", "bld", version(2,0,1))) .include(dependency("com.uwyn.rife2", "bld", version(1,7,5)))
.include(dependency("org.apache.commons", "commons-compress", version(1,27,1))); .include(dependency("org.apache.commons", "commons-compress", version(1,24,0)));
scope(test) scope(test)
.include(dependency("org.junit.jupiter", "junit-jupiter", version(5,11,0))) .include(dependency("org.junit.jupiter", "junit-jupiter", version(5,10,0)))
.include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1,11,0))); .include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1,10,0)));
javadocOperation() javadocOperation()
.javadocOptions() .javadocOptions()
@ -41,7 +41,6 @@ public class ArchiveBuild extends Project {
publishOperation() publishOperation()
.repository(version.isSnapshot() ? repository("rife2-snapshots") : repository("rife2-releases")) .repository(version.isSnapshot() ? repository("rife2-snapshots") : repository("rife2-releases"))
.repository(repository("github"))
.info() .info()
.groupId("com.uwyn.rife2") .groupId("com.uwyn.rife2")
.artifactId("bld-archive") .artifactId("bld-archive")

View file

@ -7,20 +7,15 @@ package rife.bld.extension;
import org.apache.commons.compress.archivers.zip.UnixStat; import org.apache.commons.compress.archivers.zip.UnixStat;
import org.apache.commons.compress.archivers.zip.ZipArchiveEntry; import org.apache.commons.compress.archivers.zip.ZipArchiveEntry;
import org.apache.commons.compress.archivers.zip.ZipArchiveOutputStream; import org.apache.commons.compress.archivers.zip.ZipArchiveOutputStream;
import org.apache.commons.io.IOUtils; import org.apache.commons.compress.utils.IOUtils;
import rife.bld.NamedFile; import rife.bld.NamedFile;
import rife.bld.operations.AbstractOperation; import rife.bld.operations.AbstractOperation;
import rife.tools.FileUtils; import rife.tools.FileUtils;
import rife.tools.StringUtils; import rife.tools.StringUtils;
import java.io.File; import java.io.*;
import java.io.IOException;
import java.io.InputStream;
import java.nio.file.Files; import java.nio.file.Files;
import java.nio.file.Path; import java.util.*;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.regex.Pattern; import java.util.regex.Pattern;
/** /**
@ -140,49 +135,10 @@ public class ZipOperation extends AbstractOperation<ZipOperation> {
* *
* @param directories source directories * @param directories source directories
* @return this operation instance * @return this operation instance
* @see #sourceDirectories(List)
* @since 1.0 * @since 1.0
*/ */
public ZipOperation sourceDirectories(File... directories) { public ZipOperation sourceDirectories(File... directories) {
return sourceDirectories(List.of(directories)); sourceDirectories_.addAll(List.of(directories));
}
/**
* Provides source directories that will be used for the zip archive creation.
*
* @param directories source directories
* @return this operation instance
* @see #sourceDirectoriesPaths(List)
* @since 1.0
*/
public ZipOperation sourceDirectories(Path... directories) {
return sourceDirectoriesPaths(List.of(directories));
}
/**
* Provides source directories that will be used for the zip archive creation.
*
* @param directories source directories
* @return this operation instance
* @see #sourceDirectoriesStrings(List)
* @since 1.0
*/
public ZipOperation sourceDirectories(String... directories) {
return sourceDirectoriesStrings(List.of(directories));
}
/**
* Provides a list of source directories that will be used for the zip archive creation.
* <p>
* A copy will be created to allow this list to be independently modifiable.
*
* @param directories a list of source directories
* @return this operation instance
* @see #sourceDirectories(File...)
* @since 1.0
*/
public ZipOperation sourceDirectories(List<File> directories) {
sourceDirectories_.addAll(directories);
return this; return this;
} }
@ -193,25 +149,11 @@ public class ZipOperation extends AbstractOperation<ZipOperation> {
* *
* @param directories a list of source directories * @param directories a list of source directories
* @return this operation instance * @return this operation instance
* @see #sourceDirectories(Path...)
* @since 1.0 * @since 1.0
*/ */
public ZipOperation sourceDirectoriesPaths(List<Path> directories) { public ZipOperation sourceDirectories(List<File> directories) {
return sourceDirectories(directories.stream().map(Path::toFile).toList()); sourceDirectories_.addAll(directories);
} return this;
/**
* Provides a list of source directories that will be used for the zip archive creation.
* <p>
* A copy will be created to allow this list to be independently modifiable.
*
* @param directories a list of source directories
* @return this operation instance
* @see #sourceDirectories(String...)
* @since 1.0
*/
public ZipOperation sourceDirectoriesStrings(List<String> directories) {
return sourceDirectories(directories.stream().map(File::new).toList());
} }
/** /**
@ -252,28 +194,6 @@ public class ZipOperation extends AbstractOperation<ZipOperation> {
return this; return this;
} }
/**
* Provides the destination directory in which the zip archive will be created.
*
* @param directory the zip destination directory
* @return this operation instance
* @since 1.0
*/
public ZipOperation destinationDirectory(Path directory) {
return destinationDirectory(directory.toFile());
}
/**
* Provides the destination directory in which the zip archive will be created.
*
* @param directory the zip destination directory
* @return this operation instance
* @since 1.0
*/
public ZipOperation destinationDirectory(String directory) {
return destinationDirectory(new File(directory));
}
/** /**
* Provides the destination file name that will be used for the zip archive creation. * Provides the destination file name that will be used for the zip archive creation.
* *