mirror of
https://github.com/tw93/Mole.git
synced 2026-03-22 21:55:08 +00:00
feat(clean): add Maven local repository cleanup support
This commit is contained in:
15
lib/clean/maven.sh
Normal file
15
lib/clean/maven.sh
Normal file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
# Maven Repository Cleanup Module
|
||||
set -euo pipefail
|
||||
|
||||
# Maven local repository cleanup.
|
||||
# Path: ~/.m2/repository
|
||||
# Note: This path is in the default whitelist. Remove from whitelist to enable cleanup.
|
||||
clean_maven_repository() {
|
||||
local maven_repo="$HOME/.m2/repository"
|
||||
|
||||
# Only clean if the directory exists
|
||||
[[ -d "$maven_repo" ]] || return 0
|
||||
|
||||
safe_clean "$maven_repo"/* "Maven local repository"
|
||||
}
|
||||
Reference in New Issue
Block a user