forked from phoedos/pmd
Fix assembly-plugin warnings
Don't override "finalName" anymore. This however changes the filenames of the generated binary distribution files.
This commit is contained in:
parent
7a89f550d9
commit
d77ebbe9b7
12
.ci/build.sh
12
.ci/build.sh
@ -177,8 +177,8 @@ function pmd_ci_build_run() {
|
||||
#
|
||||
function pmd_ci_deploy_build_artifacts() {
|
||||
# Deploy to sourceforge files https://sourceforge.net/projects/pmd/files/pmd/
|
||||
pmd_ci_sourceforge_uploadFile "pmd/${PMD_CI_MAVEN_PROJECT_VERSION}" "pmd-dist/target/pmd-bin-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
pmd_ci_sourceforge_uploadFile "pmd/${PMD_CI_MAVEN_PROJECT_VERSION}" "pmd-dist/target/pmd-src-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
pmd_ci_sourceforge_uploadFile "pmd/${PMD_CI_MAVEN_PROJECT_VERSION}" "pmd-dist/target/pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-bin.zip"
|
||||
pmd_ci_sourceforge_uploadFile "pmd/${PMD_CI_MAVEN_PROJECT_VERSION}" "pmd-dist/target/pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-src.zip"
|
||||
|
||||
if pmd_ci_maven_isReleaseBuild; then
|
||||
# create a draft github release
|
||||
@ -186,8 +186,8 @@ function pmd_ci_deploy_build_artifacts() {
|
||||
GH_RELEASE="$RESULT"
|
||||
|
||||
# Deploy to github releases
|
||||
pmd_ci_gh_releases_uploadAsset "$GH_RELEASE" "pmd-dist/target/pmd-bin-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
pmd_ci_gh_releases_uploadAsset "$GH_RELEASE" "pmd-dist/target/pmd-src-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
pmd_ci_gh_releases_uploadAsset "$GH_RELEASE" "pmd-dist/target/pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-bin.zip"
|
||||
pmd_ci_gh_releases_uploadAsset "$GH_RELEASE" "pmd-dist/target/pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-src.zip"
|
||||
fi
|
||||
}
|
||||
|
||||
@ -201,11 +201,11 @@ function pmd_ci_build_and_upload_doc() {
|
||||
|
||||
pmd_ci_sourceforge_uploadFile "pmd/${PMD_CI_MAVEN_PROJECT_VERSION}" "docs/pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
if pmd_ci_maven_isReleaseBuild; then
|
||||
pmd_ci_gh_releases_uploadAsset "$GH_RELEASE" "docs/pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
pmd_ci_gh_releases_uploadAsset "$GH_RELEASE" "docs/pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-doc.zip"
|
||||
fi
|
||||
|
||||
# Deploy doc to https://docs.pmd-code.org/pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}/
|
||||
pmd_code_uploadDocumentation "${PMD_CI_MAVEN_PROJECT_VERSION}" "docs/pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
pmd_code_uploadDocumentation "${PMD_CI_MAVEN_PROJECT_VERSION}" "docs/pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-doc.zip"
|
||||
# Deploy javadoc to https://docs.pmd-code.org/apidocs/*/${PMD_CI_MAVEN_PROJECT_VERSION}/
|
||||
pmd_code_uploadJavadoc "${PMD_CI_MAVEN_PROJECT_VERSION}" "$(pwd)"
|
||||
|
||||
|
@ -35,8 +35,8 @@ function pmd_doc_create_archive() {
|
||||
echo -e "\n\n"
|
||||
pmd_ci_log_info "Creating pmd-doc archive..."
|
||||
mv _site "pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}"
|
||||
zip -qr "pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}.zip" "pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}/"
|
||||
pmd_ci_log_success "Successfully created pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}.zip"
|
||||
zip -qr "pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-doc.zip" "pmd-doc-${PMD_CI_MAVEN_PROJECT_VERSION}/"
|
||||
pmd_ci_log_success "Successfully created pmd-dist-${PMD_CI_MAVEN_PROJECT_VERSION}-doc.zip"
|
||||
|
||||
popd || exit 1
|
||||
}
|
||||
|
@ -39,6 +39,11 @@ for all.</p>
|
||||
This section lists the most important changes from the last release candidate.
|
||||
The remaining section describe the complete release notes for 7.0.0.
|
||||
|
||||
Incompatible changes:
|
||||
* The asset filenames of PMD on [GitHub Releases](https://github.com/pmd/pmd/releases) are
|
||||
now `pmd-dist-<version>-bin.zip` and `pmd-dist-<version>-src.zip`. Keep that in mind, if you have an automated
|
||||
download script.
|
||||
|
||||
Fixed Issues:
|
||||
* java-codestyle
|
||||
* [#4273](https://github.com/pmd/pmd/issues/4273): \[java] CommentDefaultAccessModifier ignoredAnnotations should include "org.junit.jupiter.api.extension.RegisterExtension" by default
|
||||
|
@ -656,6 +656,9 @@ The following previously deprecated rules have been finally removed:
|
||||
to be reviewed.
|
||||
* Custom rules using rulechains: Need to override {% jdoc core::lang.rule.AbstractRule#buildTargetSelector() %}
|
||||
using {% jdoc core::lang.rule.RuleTargetSelector#forTypes(java.lang.Class,java.lang.Class...) %}.
|
||||
* The asset filenames of PMD on [GitHub Releases](https://github.com/pmd/pmd/releases) are
|
||||
now `pmd-dist-<version>-bin.zip` and `pmd-dist-<version>-src.zip`. Keep that in mind, if you have an automated
|
||||
download script.
|
||||
|
||||
### For integrators
|
||||
|
||||
|
@ -42,7 +42,7 @@
|
||||
<plugin>
|
||||
<artifactId>maven-assembly-plugin</artifactId>
|
||||
<configuration>
|
||||
<appendAssemblyId>false</appendAssemblyId>
|
||||
<appendAssemblyId>true</appendAssemblyId>
|
||||
<attach>false</attach>
|
||||
<archiverConfig>
|
||||
<defaultDirectoryMode>493</defaultDirectoryMode> <!-- 0755 -->
|
||||
@ -56,7 +56,6 @@
|
||||
<goal>single</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<finalName>${pmd.dist.bin.baseDirectory}</finalName>
|
||||
<descriptors>
|
||||
<descriptor>src/main/resources/assemblies/pmd-bin.xml</descriptor>
|
||||
</descriptors>
|
||||
@ -69,7 +68,6 @@
|
||||
<goal>single</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<finalName>pmd-src-${project.version}</finalName>
|
||||
<descriptors>
|
||||
<descriptor>src/main/resources/assemblies/pmd-src.xml</descriptor>
|
||||
</descriptors>
|
||||
|
@ -1,7 +1,7 @@
|
||||
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
|
||||
|
||||
<id>pmd-bin</id>
|
||||
<id>bin</id>
|
||||
<formats>
|
||||
<format>zip</format>
|
||||
</formats>
|
||||
|
@ -1,7 +1,7 @@
|
||||
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
|
||||
|
||||
<id>pmd-src</id>
|
||||
<id>src</id>
|
||||
<formats>
|
||||
<format>zip</format>
|
||||
</formats>
|
||||
|
@ -15,10 +15,10 @@ import org.junit.jupiter.api.io.TempDir;
|
||||
import net.sourceforge.pmd.PMDVersion;
|
||||
|
||||
abstract class AbstractBinaryDistributionTest {
|
||||
public static final String PMD_BIN_PREFIX = "pmd-bin-";
|
||||
public static final String PMD_BIN_PREFIX = "pmd-bin-" + PMDVersion.VERSION;
|
||||
|
||||
protected static File getBinaryDistribution() {
|
||||
return new File(".", "target/" + PMD_BIN_PREFIX + PMDVersion.VERSION + ".zip");
|
||||
return new File(".", "target/pmd-dist-" + PMDVersion.VERSION + "-bin.zip");
|
||||
}
|
||||
|
||||
@TempDir
|
||||
|
@ -21,7 +21,6 @@ import org.junit.jupiter.api.Test;
|
||||
import org.junit.jupiter.api.condition.EnabledOnOs;
|
||||
import org.junit.jupiter.api.condition.OS;
|
||||
|
||||
import net.sourceforge.pmd.PMDVersion;
|
||||
import net.sourceforge.pmd.internal.util.IOUtil;
|
||||
|
||||
/**
|
||||
@ -36,7 +35,7 @@ class AntIT extends AbstractBinaryDistributionTest {
|
||||
@EnabledOnOs(OS.LINUX)
|
||||
void runAnt() throws IOException, InterruptedException {
|
||||
String antBasepath = new File("target/ant").getAbsolutePath();
|
||||
String pmdHome = tempDir.resolve(PMD_BIN_PREFIX + PMDVersion.VERSION).toAbsolutePath().toString();
|
||||
String pmdHome = tempDir.resolve(PMD_BIN_PREFIX).toAbsolutePath().toString();
|
||||
File antTestProjectFolder = prepareAntTestProjectFolder();
|
||||
|
||||
ExecutionResult result = runAnt(antBasepath, pmdHome, antTestProjectFolder);
|
||||
|
@ -16,7 +16,6 @@ import java.util.concurrent.TimeUnit;
|
||||
|
||||
import org.apache.commons.lang3.SystemUtils;
|
||||
|
||||
import net.sourceforge.pmd.PMDVersion;
|
||||
import net.sourceforge.pmd.internal.util.IOUtil;
|
||||
|
||||
/**
|
||||
@ -37,7 +36,7 @@ public class PMDExecutor {
|
||||
}
|
||||
|
||||
private static ExecutionResult runPMDUnix(Path tempDir, Path reportFile, String... arguments) throws Exception {
|
||||
String cmd = tempDir.resolve(AbstractBinaryDistributionTest.PMD_BIN_PREFIX + PMDVersion.VERSION + "/bin/pmd").toAbsolutePath().toString();
|
||||
String cmd = tempDir.resolve(AbstractBinaryDistributionTest.PMD_BIN_PREFIX + "/bin/pmd").toAbsolutePath().toString();
|
||||
List<String> args = new ArrayList<>();
|
||||
args.add("check");
|
||||
args.addAll(Arrays.asList(arguments));
|
||||
@ -45,7 +44,7 @@ public class PMDExecutor {
|
||||
}
|
||||
|
||||
private static ExecutionResult runPMDWindows(Path tempDir, Path reportFile, String... arguments) throws Exception {
|
||||
String cmd = tempDir.resolve(AbstractBinaryDistributionTest.PMD_BIN_PREFIX + PMDVersion.VERSION + "/bin/pmd.bat").toAbsolutePath().toString();
|
||||
String cmd = tempDir.resolve(AbstractBinaryDistributionTest.PMD_BIN_PREFIX + "/bin/pmd.bat").toAbsolutePath().toString();
|
||||
List<String> args = new ArrayList<>();
|
||||
args.add("check");
|
||||
args.addAll(Arrays.asList(arguments));
|
||||
|
@ -20,7 +20,7 @@ class SourceDistributionIT {
|
||||
private static final String BASE_PATH = "pmd-src-" + PMDVersion.VERSION;
|
||||
|
||||
private File getSourceDistribution() {
|
||||
return new File(".", "target/" + BASE_PATH + ".zip");
|
||||
return new File(".", "target/pmd-dist-" + PMDVersion.VERSION + "-src.zip");
|
||||
}
|
||||
|
||||
@Test
|
||||
|
Loading…
x
Reference in New Issue
Block a user