You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Updated after I identified a version mismatch between the dependency entry and plugin entry.
summary of problem
Supplying -DspotlessFiles= to check or apply appears to be ineffectual. Running without the switch returns violations, if I specify a file I know contains violations, the maven task runs successfully with no error output.
gradle or maven version
Maven 3.6.1
spotless version
Tested 1.24.1 and 1.24.3
operating system and version
macOS 10.14.6
[/] copy-paste your full Spotless configuration block(s), and a link to a public git repo that reproduces the problem if possible
copy-paste the full content of any console errors emitted by maven spotless:[apply/check] -DspotlessFiles=relative/path/to/known/bad/file.java -X
There do not appear to be any obvious errors to why the parameter is ignored
mvn spotless:check -DspotlessFiles=FileName.java -X
[MVNVM] Using maven: 3.6.1
Apache Maven 3.6.1 (d66c9c0b3152b2e69ee9bac180bb8fcc8e6af555; 2019-04-04T15:00:29-04:00)
Maven home: /Users/me/.mvnvm/apache-maven-3.6.1
Java version: 1.8.0_202, vendor: Oracle Corporation, runtime: /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "mac os x", version: "10.14.6", arch: "x86_64", family: "mac"
[DEBUG] Created new class realm maven.api
[DEBUG] Importing foreign packages into class realm maven.api
[DEBUG] Imported: javax.annotation.* < plexus.core
[DEBUG] Imported: javax.annotation.security.* < plexus.core
[DEBUG] Imported: javax.enterprise.inject.* < plexus.core
[DEBUG] Imported: javax.enterprise.util.* < plexus.core
[DEBUG] Imported: javax.inject.* < plexus.core
[DEBUG] Imported: org.apache.maven.* < plexus.core
[DEBUG] Imported: org.apache.maven.artifact < plexus.core
[DEBUG] Imported: org.apache.maven.classrealm < plexus.core
[DEBUG] Imported: org.apache.maven.cli < plexus.core
[DEBUG] Imported: org.apache.maven.configuration < plexus.core
[DEBUG] Imported: org.apache.maven.exception < plexus.core
[DEBUG] Imported: org.apache.maven.execution < plexus.core
[DEBUG] Imported: org.apache.maven.execution.scope < plexus.core
[DEBUG] Imported: org.apache.maven.lifecycle < plexus.core
[DEBUG] Imported: org.apache.maven.model < plexus.core
[DEBUG] Imported: org.apache.maven.monitor < plexus.core
[DEBUG] Imported: org.apache.maven.plugin < plexus.core
[DEBUG] Imported: org.apache.maven.profiles < plexus.core
[DEBUG] Imported: org.apache.maven.project < plexus.core
[DEBUG] Imported: org.apache.maven.reporting < plexus.core
[DEBUG] Imported: org.apache.maven.repository < plexus.core
[DEBUG] Imported: org.apache.maven.rtinfo < plexus.core
[DEBUG] Imported: org.apache.maven.settings < plexus.core
[DEBUG] Imported: org.apache.maven.toolchain < plexus.core
[DEBUG] Imported: org.apache.maven.usability < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.* < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.authentication < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.authorization < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.events < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.observers < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.proxy < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.repository < plexus.core
[DEBUG] Imported: org.apache.maven.wagon.resource < plexus.core
[DEBUG] Imported: org.codehaus.classworlds < plexus.core
[DEBUG] Imported: org.codehaus.plexus.* < plexus.core
[DEBUG] Imported: org.codehaus.plexus.classworlds < plexus.core
[DEBUG] Imported: org.codehaus.plexus.component < plexus.core
[DEBUG] Imported: org.codehaus.plexus.configuration < plexus.core
[DEBUG] Imported: org.codehaus.plexus.container < plexus.core
[DEBUG] Imported: org.codehaus.plexus.context < plexus.core
[DEBUG] Imported: org.codehaus.plexus.lifecycle < plexus.core
[DEBUG] Imported: org.codehaus.plexus.logging < plexus.core
[DEBUG] Imported: org.codehaus.plexus.personality < plexus.core
[DEBUG] Imported: org.codehaus.plexus.util.xml.Xpp3Dom < plexus.core
[DEBUG] Imported: org.codehaus.plexus.util.xml.pull.XmlPullParser < plexus.core
[DEBUG] Imported: org.codehaus.plexus.util.xml.pull.XmlPullParserException < plexus.core
[DEBUG] Imported: org.codehaus.plexus.util.xml.pull.XmlSerializer < plexus.core
[DEBUG] Imported: org.eclipse.aether.* < plexus.core
[DEBUG] Imported: org.eclipse.aether.artifact < plexus.core
[DEBUG] Imported: org.eclipse.aether.collection < plexus.core
[DEBUG] Imported: org.eclipse.aether.deployment < plexus.core
[DEBUG] Imported: org.eclipse.aether.graph < plexus.core
[DEBUG] Imported: org.eclipse.aether.impl < plexus.core
[DEBUG] Imported: org.eclipse.aether.installation < plexus.core
[DEBUG] Imported: org.eclipse.aether.internal.impl < plexus.core
[DEBUG] Imported: org.eclipse.aether.metadata < plexus.core
[DEBUG] Imported: org.eclipse.aether.repository < plexus.core
[DEBUG] Imported: org.eclipse.aether.resolution < plexus.core
[DEBUG] Imported: org.eclipse.aether.spi < plexus.core
[DEBUG] Imported: org.eclipse.aether.transfer < plexus.core
[DEBUG] Imported: org.eclipse.aether.version < plexus.core
[DEBUG] Imported: org.fusesource.jansi.* < plexus.core
[DEBUG] Imported: org.slf4j.* < plexus.core
[DEBUG] Imported: org.slf4j.event.* < plexus.core
[DEBUG] Imported: org.slf4j.helpers.* < plexus.core
[DEBUG] Imported: org.slf4j.spi.* < plexus.core
[DEBUG] Populating class realm maven.api
[INFO] Error stacktraces are turned on.
[DEBUG] Message scheme: color
[DEBUG] Message styles: debug info warning error success failure strong mojo project
[DEBUG] Reading global settings from /Users/me/.mvnvm/apache-maven-3.6.1/conf/settings.xml
[DEBUG] Reading user settings from /Users/me/.m2/settings.xml
[DEBUG] Reading global toolchains from /Users/me/.mvnvm/apache-maven-3.6.1/conf/toolchains.xml
[DEBUG] Reading user toolchains from /Users/me/.m2/toolchains.xml
[DEBUG] Using local repository at /Users/me/.m2/repository
[DEBUG] Using manager EnhancedLocalRepositoryManager with priority 10.0 for /Users/me/.m2/repository
[INFO] Scanning for projects...
[DEBUG] Dependency collection stats: {ConflictMarker.analyzeTime=1956189, ConflictMarker.markTime=1116897, ConflictMarker.nodeCount=206, ConflictIdSorter.graphTime=1031756, ConflictIdSorter.topsortTime=621452, ConflictIdSorter.conflictIdCount=64, ConflictIdSorter.conflictIdCycleCount=0, ConflictResolver.totalTime=10527577, ConflictResolver.conflictItemCount=133, DefaultDependencyCollector.collectTime=549330070, DefaultDependencyCollector.transformTime=17658056}
[DEBUG] org.apache.felix:maven-bundle-plugin:jar:3.5.0:
[DEBUG] org.osgi:org.osgi.core:jar:4.3.1:compile
[DEBUG] biz.aQute.bnd:biz.aQute.bndlib:jar:3.5.0:compile
[DEBUG] org.apache.felix:org.apache.felix.bundlerepository:jar:1.6.6:compile
[DEBUG] org.easymock:easymock:jar:3.4:compile
[DEBUG] org.objenesis:objenesis:jar:2.2:compile
[DEBUG] org.apache.felix:org.apache.felix.utils:jar:1.6.0:compile
[DEBUG] org.osgi:org.osgi.compendium:jar:4.2.0:compile
[DEBUG] org.apache.maven:maven-core:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-settings:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-plugin-parameter-documenter:jar:2.2.0:compile
[DEBUG] org.slf4j:slf4j-jdk14:jar:1.5.6:runtime
[DEBUG] org.slf4j:slf4j-api:jar:1.5.6:runtime
[DEBUG] org.slf4j:jcl-over-slf4j:jar:1.5.6:runtime
[DEBUG] org.apache.maven.reporting:maven-reporting-api:jar:2.2.0:compile
[DEBUG] org.apache.maven.doxia:doxia-logging-api:jar:1.1:compile
[DEBUG] org.apache.maven:maven-profile:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-model:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-artifact:jar:2.2.0:compile
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1:compile
[DEBUG] junit:junit:jar:4.12:compile
[DEBUG] org.hamcrest:hamcrest-core:jar:1.3:compile
[DEBUG] org.apache.maven:maven-repository-metadata:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-error-diagnostics:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-project:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-plugin-registry:jar:2.2.0:compile
[DEBUG] commons-cli:commons-cli:jar:1.2:compile
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.2.0:compile
[DEBUG] org.apache.maven:maven-plugin-descriptor:jar:2.2.0:compile
[DEBUG] org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4:compile
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.2.0:compile
[DEBUG] backport-util-concurrent:backport-util-concurrent:jar:3.1:compile
[DEBUG] org.apache.maven:maven-monitor:jar:2.2.0:compile
[DEBUG] classworlds:classworlds:jar:1.1:compile
[DEBUG] org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3:compile
[DEBUG] org.sonatype.plexus:plexus-cipher:jar:1.4:compile
[DEBUG] org.apache.maven:maven-archiver:jar:2.6:compile
[DEBUG] org.apache.maven.shared:maven-shared-utils:jar:0.7:compile
[DEBUG] com.google.code.findbugs:jsr305:jar:2.0.1:compile
[DEBUG] org.codehaus.plexus:plexus-archiver:jar:2.8.1:compile
[DEBUG] org.codehaus.plexus:plexus-io:jar:2.3.2:compile
[DEBUG] org.apache.commons:commons-compress:jar:1.9:compile
[DEBUG] org.codehaus.plexus:plexus-interpolation:jar:1.21:compile
[DEBUG] org.apache.maven.shared:maven-dependency-tree:jar:2.1:compile
[DEBUG] org.codehaus.plexus:plexus-component-annotations:jar:1.5.5:compile
[DEBUG] org.eclipse.aether:aether-util:jar:0.9.0.M2:compile
[DEBUG] org.codehaus.plexus:plexus-utils:jar:3.0.10:compile
[DEBUG] org.sonatype.plexus:plexus-build-api:jar:0.0.7:compile
[DEBUG] org.apache.maven.doxia:doxia-sink-api:jar:1.0:compile
[DEBUG] org.apache.maven.doxia:doxia-site-renderer:jar:1.0:compile
[DEBUG] org.apache.maven.doxia:doxia-core:jar:1.0:compile
[DEBUG] org.codehaus.plexus:plexus-i18n:jar:1.0-beta-7:compile
[DEBUG] org.codehaus.plexus:plexus-velocity:jar:1.1.7:compile
[DEBUG] org.apache.velocity:velocity:jar:1.5:compile
[DEBUG] commons-lang:commons-lang:jar:2.1:compile
[DEBUG] oro:oro:jar:2.0.8:compile
[DEBUG] org.apache.maven.doxia:doxia-decoration-model:jar:1.0:compile
[DEBUG] commons-collections:commons-collections:jar:3.2:compile
[DEBUG] org.apache.maven.doxia:doxia-module-apt:jar:1.0:compile
[DEBUG] org.apache.maven.doxia:doxia-module-fml:jar:1.0:compile
[DEBUG] org.apache.maven.doxia:doxia-module-xdoc:jar:1.0:compile
[DEBUG] org.apache.maven.doxia:doxia-module-xhtml:jar:1.0:compile
[DEBUG] org.jdom:jdom:jar:1.1:compile
[DEBUG] Created new class realm extension>org.apache.felix:maven-bundle-plugin:3.5.0
[DEBUG] Importing foreign packages into class realm extension>org.apache.felix:maven-bundle-plugin:3.5.0
[DEBUG] Imported: < maven.api
[DEBUG] Populating class realm extension>org.apache.felix:maven-bundle-plugin:3.5.0
[DEBUG] Included: org.apache.felix:maven-bundle-plugin:jar:3.5.0
[DEBUG] Included: org.osgi:org.osgi.core:jar:4.3.1
[DEBUG] Included: biz.aQute.bnd:biz.aQute.bndlib:jar:3.5.0
[DEBUG] Included: org.apache.felix:org.apache.felix.bundlerepository:jar:1.6.6
[DEBUG] Included: org.easymock:easymock:jar:3.4
[DEBUG] Included: org.objenesis:objenesis:jar:2.2
[DEBUG] Included: org.apache.felix:org.apache.felix.utils:jar:1.6.0
[DEBUG] Included: org.osgi:org.osgi.compendium:jar:4.2.0
[DEBUG] Included: org.slf4j:slf4j-jdk14:jar:1.5.6
[DEBUG] Included: org.slf4j:jcl-over-slf4j:jar:1.5.6
[DEBUG] Included: org.apache.maven.reporting:maven-reporting-api:jar:2.2.0
[DEBUG] Included: org.apache.maven.doxia:doxia-logging-api:jar:1.1
[DEBUG] Included: junit:junit:jar:4.12
[DEBUG] Included: org.hamcrest:hamcrest-core:jar:1.3
[DEBUG] Included: commons-cli:commons-cli:jar:1.2
[DEBUG] Included: org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4
[DEBUG] Included: backport-util-concurrent:backport-util-concurrent:jar:3.1
[DEBUG] Included: org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3
[DEBUG] Included: org.sonatype.plexus:plexus-cipher:jar:1.4
[DEBUG] Included: org.apache.maven:maven-archiver:jar:2.6
[DEBUG] Included: org.apache.maven.shared:maven-shared-utils:jar:0.7
[DEBUG] Included: com.google.code.findbugs:jsr305:jar:2.0.1
[DEBUG] Included: org.codehaus.plexus:plexus-archiver:jar:2.8.1
[DEBUG] Included: org.codehaus.plexus:plexus-io:jar:2.3.2
[DEBUG] Included: org.apache.commons:commons-compress:jar:1.9
[DEBUG] Included: org.codehaus.plexus:plexus-interpolation:jar:1.21
[DEBUG] Included: org.apache.maven.shared:maven-dependency-tree:jar:2.1
[DEBUG] Included: org.codehaus.plexus:plexus-component-annotations:jar:1.5.5
[DEBUG] Included: org.eclipse.aether:aether-util:jar:0.9.0.M2
[DEBUG] Included: org.codehaus.plexus:plexus-utils:jar:3.0.10
[DEBUG] Included: org.sonatype.plexus:plexus-build-api:jar:0.0.7
[DEBUG] Included: org.apache.maven.doxia:doxia-sink-api:jar:1.0
[DEBUG] Included: org.apache.maven.doxia:doxia-site-renderer:jar:1.0
[DEBUG] Included: org.apache.maven.doxia:doxia-core:jar:1.0
[DEBUG] Included: org.codehaus.plexus:plexus-i18n:jar:1.0-beta-7
[DEBUG] Included: org.codehaus.plexus:plexus-velocity:jar:1.1.7
[DEBUG] Included: org.apache.velocity:velocity:jar:1.5
[DEBUG] Included: commons-lang:commons-lang:jar:2.1
[DEBUG] Included: oro:oro:jar:2.0.8
[DEBUG] Included: org.apache.maven.doxia:doxia-decoration-model:jar:1.0
[DEBUG] Included: commons-collections:commons-collections:jar:3.2
[DEBUG] Included: org.apache.maven.doxia:doxia-module-apt:jar:1.0
[DEBUG] Included: org.apache.maven.doxia:doxia-module-fml:jar:1.0
[DEBUG] Included: org.apache.maven.doxia:doxia-module-xdoc:jar:1.0
[DEBUG] Included: org.apache.maven.doxia:doxia-module-xhtml:jar:1.0
[DEBUG] Included: org.jdom:jdom:jar:1.1
[DEBUG] Extension realms for project org.organization.www:organization-subproject-api:bundle:1.0.1-SNAPSHOT: [ClassRealm[extension>org.apache.felix:maven-bundle-plugin:3.5.0, parent: sun.misc.Launcher$AppClassLoader@5c647e05]]
[DEBUG] Created new class realm project>org.organization.www:organization-subproject-api:1.0.1-SNAPSHOT
[DEBUG] Populating class realm project>org.organization.www:organization-subproject-api:1.0.1-SNAPSHOT
[DEBUG] Looking up lifecycle mappings for packaging bundle from ClassRealm[project>org.organization.www:organization-subproject-api:1.0.1-SNAPSHOT, parent: ClassRealm[maven.api, parent: null]]
[DEBUG] Extension realms for project org.organization.www:organization-subproject-service-aggregator:pom:1.0-SNAPSHOT: (none)
[DEBUG] Looking up lifecycle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[DEBUG] Extension realms for project org.organization.www:organization-subproject-aggregator:pom:1.0-SNAPSHOT: (none)
[DEBUG] Looking up lifecycle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[DEBUG] Extension realms for project org.organization.www:organization-parent:pom:1.0-SNAPSHOT: (none)
[DEBUG] Looking up lifecycle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[WARNING]
[WARNING] Some problems were encountered while building the effective model for org.organization.www:organization-subproject-api:bundle:1.0.1-SNAPSHOT
[WARNING] 'version' contains an expression but should be a constant. @ org.organization.www:organization-subproject-api:1.0.1-${build.qualifier}, /Users/me/Developer/project/organization-subproject/services/api/pom.xml, line 15, column 12
[WARNING] 'dependencyManagement.dependencies.dependency.(groupId:artifactId:type:classifier)' must be unique: org.apache.commons:commons-lang3:jar -> version 3.5 vs 3.0 @ org.organization.www:organization-parent:1.0-SNAPSHOT, /Users/me/Developer/project/parent/pom.xml, line 815, column 19
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[DEBUG] Could not find metadata org.apache.maven.plugins:maven-install-plugin/maven-metadata.xml in local (/Users/me/.m2/repository)
[DEBUG] Failure to find org.apache.maven.plugins:maven-install-plugin/maven-metadata.xml in https://repo.adobe.com/nexus/content/groups/public was cached in the local repository, resolution will not be reattempted until the update interval of adobe-public-releases has elapsed or updates are forced
[DEBUG] Skipped remote request for org.apache.maven.plugins:maven-install-plugin/maven-metadata.xml, locally cached metadata up-to-date.
[DEBUG] Resolved plugin version for org.apache.maven.plugins:maven-install-plugin to 3.0.0-M1 from repository central (https://repo.maven.apache.org/maven2, default, releases)
[DEBUG] Could not find metadata org.apache.maven.plugins:maven-deploy-plugin/maven-metadata.xml in local (/Users/me/.m2/repository)
[DEBUG] Failure to find org.apache.maven.plugins:maven-deploy-plugin/maven-metadata.xml in https://repo.adobe.com/nexus/content/groups/public was cached in the local repository, resolution will not be reattempted until the update interval of adobe-public-releases has elapsed or updates are forced
[DEBUG] Skipped remote request for org.apache.maven.plugins:maven-deploy-plugin/maven-metadata.xml, locally cached metadata up-to-date.
[DEBUG] Resolved plugin version for org.apache.maven.plugins:maven-deploy-plugin to 3.0.0-M1 from repository central (https://repo.maven.apache.org/maven2, default, releases)
[DEBUG] Resolving plugin prefix spotless from [org.apache.maven.plugins, org.codehaus.mojo]
[DEBUG] Resolved plugin prefix spotless to com.diffplug.spotless:spotless-maven-plugin from POM org.organization.www:organization-subproject-api:bundle:1.0.1-SNAPSHOT
[DEBUG] === REACTOR BUILD PLAN ================================================
[DEBUG] Project: org.organization.www:organization-subproject-api:bundle:1.0.1-SNAPSHOT
[DEBUG] Tasks: [spotless:check]
[DEBUG] Style: Regular
[DEBUG] =======================================================================
[INFO]
[INFO] ------------------< org.organization.www:organization-subproject-api >------------------
[INFO] Building organization subproject API 1.0.1-SNAPSHOT
[INFO] -------------------------------[ bundle ]-------------------------------
[DEBUG] Resolving plugin prefix spotless from [org.apache.maven.plugins, org.codehaus.mojo]
[DEBUG] Resolved plugin prefix spotless to com.diffplug.spotless:spotless-maven-plugin from POM org.organization.www:organization-subproject-api:bundle:1.0.1-SNAPSHOT
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] === PROJECT BUILD PLAN ================================================
[DEBUG] Project: org.organization.www:organization-subproject-api:1.0.1-SNAPSHOT
[DEBUG] Dependencies (collect): []
[DEBUG] Dependencies (resolve): []
[DEBUG] Repositories (dependencies): [adobe-public-releases (https://repo.adobe.com/nexus/content/groups/public, default, releases), central (https://repo.maven.apache.org/maven2, default, releases)]
[DEBUG] Repositories (plugins) : [adobe-public-releases (https://repo.adobe.com/nexus/content/groups/public, default, releases), central (https://repo.maven.apache.org/maven2, default, releases)]
[DEBUG] -----------------------------------------------------------------------
[DEBUG] Goal: com.diffplug.spotless:spotless-maven-plugin:1.24.3:check (default-cli)
[DEBUG] Style: Regular
[DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
<configuration>
<baseDir default-value="${project.basedir}"/>
<encoding default-value="UTF-8"/>
<filePatterns>${spotlessFiles}</filePatterns>
<java>
<eclipse>
<file>/Users/me/Developer/project/organization-subproject/services/api/../../../eclipse-format.java.xml</file>
<version>4.10.0</version>
</eclipse>
</java>
<lineEndings default-value="GIT_ATTRIBUTES"/>
<repositories default-value="${project.remotePluginRepositories}"/>
<repositorySystemSession default-value="${repositorySystemSession}"/>
<skip default-value="false">${spotless.check.skip}</skip>
<targetDir default-value="${project.build.directory}"/>
</configuration>
[DEBUG] =======================================================================
[INFO]
[INFO] --- spotless-maven-plugin:1.24.3:check (default-cli) @ organization-subproject-api ---
[DEBUG] Dependency collection stats: {ConflictMarker.analyzeTime=205399, ConflictMarker.markTime=103763, ConflictMarker.nodeCount=28, ConflictIdSorter.graphTime=125980, ConflictIdSorter.topsortTime=30457, ConflictIdSorter.conflictIdCount=21, ConflictIdSorter.conflictIdCycleCount=0, ConflictResolver.totalTime=749516, ConflictResolver.conflictItemCount=28, DefaultDependencyCollector.collectTime=70240198, DefaultDependencyCollector.transformTime=1241123}
[DEBUG] com.diffplug.spotless:spotless-maven-plugin:jar:1.24.3:
[DEBUG] com.diffplug.spotless:spotless-lib:jar:1.24.3:compile
[DEBUG] com.diffplug.spotless:spotless-lib-extra:jar:1.24.3:compile
[DEBUG] org.eclipse.jgit:org.eclipse.jgit:jar:5.5.0.201909110433-r:runtime
[DEBUG] com.jcraft:jsch:jar:0.1.55:runtime
[DEBUG] com.jcraft:jzlib:jar:1.1.1:runtime
[DEBUG] com.googlecode.javaewah:JavaEWAH:jar:1.1.6:runtime
[DEBUG] org.slf4j:slf4j-api:jar:1.7.2:runtime
[DEBUG] org.bouncycastle:bcpg-jdk15on:jar:1.61:runtime
[DEBUG] org.bouncycastle:bcprov-jdk15on:jar:1.61:runtime
[DEBUG] org.bouncycastle:bcpkix-jdk15on:jar:1.61:runtime
[DEBUG] com.googlecode.concurrent-trees:concurrent-trees:jar:2.6.1:runtime
[DEBUG] org.codehaus.groovy:groovy-xml:jar:2.4.7:runtime
[DEBUG] org.codehaus.groovy:groovy:jar:2.4.7:runtime
[DEBUG] org.codehaus.plexus:plexus-resources:jar:1.0.1:compile
[DEBUG] org.codehaus.plexus:plexus-utils:jar:3.0.8:compile
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1:compile
[DEBUG] junit:junit:jar:3.8.1:compile
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:compile
[DEBUG] com.diffplug.durian:durian-core:jar:1.2.0:runtime
[DEBUG] com.diffplug.durian:durian-collect:jar:1.2.0:runtime
[DEBUG] Created new class realm plugin>com.diffplug.spotless:spotless-maven-plugin:1.24.3
[DEBUG] Importing foreign packages into class realm plugin>com.diffplug.spotless:spotless-maven-plugin:1.24.3
[DEBUG] Imported: < project>org.organization.www:organization-subproject-api:1.0.1-SNAPSHOT
[DEBUG] Populating class realm plugin>com.diffplug.spotless:spotless-maven-plugin:1.24.3
[DEBUG] Included: com.diffplug.spotless:spotless-maven-plugin:jar:1.24.3
[DEBUG] Included: com.diffplug.spotless:spotless-lib:jar:1.24.3
[DEBUG] Included: com.diffplug.spotless:spotless-lib-extra:jar:1.24.3
[DEBUG] Included: org.eclipse.jgit:org.eclipse.jgit:jar:5.5.0.201909110433-r
[DEBUG] Included: com.jcraft:jsch:jar:0.1.55
[DEBUG] Included: com.jcraft:jzlib:jar:1.1.1
[DEBUG] Included: com.googlecode.javaewah:JavaEWAH:jar:1.1.6
[DEBUG] Included: org.bouncycastle:bcpg-jdk15on:jar:1.61
[DEBUG] Included: org.bouncycastle:bcprov-jdk15on:jar:1.61
[DEBUG] Included: org.bouncycastle:bcpkix-jdk15on:jar:1.61
[DEBUG] Included: com.googlecode.concurrent-trees:concurrent-trees:jar:2.6.1
[DEBUG] Included: org.codehaus.groovy:groovy-xml:jar:2.4.7
[DEBUG] Included: org.codehaus.groovy:groovy:jar:2.4.7
[DEBUG] Included: org.codehaus.plexus:plexus-resources:jar:1.0.1
[DEBUG] Included: org.codehaus.plexus:plexus-utils:jar:3.0.8
[DEBUG] Included: junit:junit:jar:3.8.1
[DEBUG] Included: com.diffplug.durian:durian-core:jar:1.2.0
[DEBUG] Included: com.diffplug.durian:durian-collect:jar:1.2.0
[DEBUG] Configuring mojo com.diffplug.spotless:spotless-maven-plugin:1.24.3:check from plugin realm ClassRealm[plugin>com.diffplug.spotless:spotless-maven-plugin:1.24.3, parent: sun.misc.Launcher$AppClassLoader@5c647e05]
[DEBUG] Configuring mojo 'com.diffplug.spotless:spotless-maven-plugin:1.24.3:check' with basic configurator -->
[DEBUG] (f) baseDir = /Users/me/Developer/project/organization-subproject/services/api
[DEBUG] (f) encoding = UTF-8
[DEBUG] (f) filePatterns = FileName.java
[DEBUG] (f) file = /Users/me/Developer/project/organization-subproject/services/api/../../../eclipse-format.java.xml
[DEBUG] (f) version = 4.10.0
[DEBUG] (s) eclipse = com.diffplug.spotless.maven.java.Eclipse@f14e5bf
[DEBUG] (f) java = com.diffplug.spotless.maven.java.Java@d176a31
[DEBUG] (f) lineEndings = GIT_ATTRIBUTES
[DEBUG] (f) repositories = [adobe-public-releases (https://repo.adobe.com/nexus/content/groups/public, default, releases), central (https://repo.maven.apache.org/maven2, default, releases)]
[DEBUG] (f) repositorySystemSession = org.eclipse.aether.DefaultRepositorySystemSession@1bcf67e8
[DEBUG] (f) skip = false
[DEBUG] (f) targetDir = /Users/me/Developer/project/organization-subproject/services/api/target
[DEBUG] -- end configuration --
[DEBUG] The resource '/Users/me/Developer/project/organization-subproject/services/api/../../../eclipse-format.java.xml' was found as /Users/me/Developer/project/organization-subproject/services/api/../../../eclipse-format.java.xml.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.765 s
[INFO] Finished at: 2019-09-25T15:22:45-04:00
[INFO] ------------------------------------------------------------------------
I've reproduced it on eclipse version 4.11.0 and 4.12.0. Versions > 4.6 and < 4.10.0 all throw errors.
The text was updated successfully, but these errors were encountered:
Ok figured this out thanks to mvnDebug. I see the note now in the docs, but as a Java dabbler it wasn't clear ;)
The inputs to spotlessFiles are java regex patterns, so it needs to explicitly allow for ^.* as the comparison is against the absolute file path.
Updated after I identified a version mismatch between the dependency entry and plugin entry.
Supplying
-DspotlessFiles=
tocheck
orapply
appears to be ineffectual. Running without the switch returns violations, if I specify a file I know contains violations, the maven task runs successfully with no error output.Maven 3.6.1
Tested 1.24.1 and 1.24.3
macOS 10.14.6
maven spotless:[apply/check] -DspotlessFiles=relative/path/to/known/bad/file.java -X
There do not appear to be any obvious errors to why the parameter is ignored
I've reproduced it on eclipse version 4.11.0 and 4.12.0. Versions > 4.6 and < 4.10.0 all throw errors.
The text was updated successfully, but these errors were encountered: