github apache/maven-clean-plugin maven-clean-plugin-4.0.0-beta-3
4.0.0-beta-3

pre-release7 hours ago

Warning

This plugin is a Maven 4 plugin and requires Maven 4.x to run.
This release brings 67 fixes, improvements and maintenance updates accumulated since beta-2, including several significant additions for Maven 4 users:

  • Fast clean is now the default (maven.clean.fast=true): the plugin stages deletions in .mvn/target/.clean before Maven's build start, dramatically reducing cold-build overhead on large projects.
  • New purge-check goal detects and removes orphaned build directories left behind by renamed or removed modules.
  • Read-only file deletion is now configurable, and <targetPath> directories are also cleaned up.
  • Under the hood: the background cleaner is now session-scoped (fixes races in multi-module builds), the Plexus dependency is replaced with java.nio, and the IT scripts have been ported from BeanShell to Groovy.

Requires Maven 4.x.

🚀 New features and improvements

  • fix: MCLEAN-102, session-scoped BackgroundCleaner, batch retry for both fast and non-fast paths (fixes #281, #285) (#347) @gnodet

  • feat: make fast clean the default (maven.clean.fast=true) (#362) @gnodet

  • feat: use .mvn/target/.clean as default staging directory for fast clean (#358) @gnodet

  • feat: add purge-check goal to detect and remove orphaned build directories (#356) @gnodet

  • Add IT for MCLEAN-104: clean lifecycle should not attempt dependency resolution (#105) @slawekjaranowski

  • Configuration parameter for deleting read-only files (#250) @desruisseaux

  • Replace Plexus dependency by more extensive usage of java.nio (#243) @desruisseaux

🐛 Bug Fixes

  • fix: fall back to original path when toRealPath() fails (fixes #262) (#344) @gnodet

  • fix: clarify that failOnError has no effect in fast mode (fixes #352) (#355) @gnodet

  • fix: missing closing brace and javadoc opener in CleanerTest (#357) @gnodet

  • Delete also the directories specified in <targetPath> (#276) @desruisseaux

📝 Documentation updates

  • Convert the FAQ from FML to Markdown (#336) @slachiewicz
  • Add AGENTS.md + SECURITY.md security-model pointer for scanner discoverability (#316) @potiuk

👻 Maintenance

🔧 Build

📦 Dependency updates

Don't miss a new maven-clean-plugin release

NewReleases is sending notifications on new releases.