Liftwizard Profile Parent

is a Maven parent POM that gives your project pre configured profiles for code formatting static analysis refactoring and more By inheriting from it you gain access to battle tested CI workflows without configuring each plugin yourself Quick Start Step 1 Set as your project s parent Step 2 Run profiles from the command line Step 3 Add GitHub Actions workflows to run these profiles in CI Here are two patterns used in production Pattern 1 Required Checks merge group Run all checks in parallel and require them to pass before merging See merge group yml for all available profiles in use Pattern 2 Auto Fix pull request Automatically fix violations and push to a fix branch See pull request yml for auto fix jobs for spotless prettier errorprone and OpenRewrite Profile List Profile ID Category Description type StrongEmphasis content text Build & Packaging type SimpleText code maven javadoc plugin type InlinedCode text Build & Packaging type SimpleText text Generate Javadoc type SimpleText code maven shade plugin type InlinedCode text Build & Packaging type SimpleText text Create uber jars type SimpleText code znai maven plugin type InlinedCode text Build & Packaging type SimpleText text Generate Znai documentation type SimpleText type StrongEmphasis content text Code Formatting type SimpleText code prettier apply type InlinedCode text Code Formatting type SimpleText text Apply Prettier formatting type SimpleText code prettier check type InlinedCode text Code Formatting type SimpleText text Check code formatting with Prettier type SimpleText code spotless antlr type InlinedCode text Code Formatting type SimpleText text ANTLR grammar formatting type SimpleText code spotless apply type InlinedCode text Code Formatting type SimpleText text Apply Spotless formatting type SimpleText code spotless check type InlinedCode text Code Formatting type SimpleText text Check code formatting with Spotless type SimpleText code spotless formats type InlinedCode text Code Formatting type SimpleText text Format gitattributes and gitignore files type SimpleText code spotless google java format type InlinedCode text Code Formatting type SimpleText text Google Java style formatting type SimpleText code spotless java type InlinedCode text Code Formatting type SimpleText text Basic Java formatting whitespace newlines type SimpleText code spotless java cleanthat type InlinedCode text Code Formatting type SimpleText text Code cleanup and refactoring type SimpleText code spotless java sort imports type InlinedCode text Code Formatting type SimpleText text Sort and organize Java imports type SimpleText code spotless java unused imports type InlinedCode text Code Formatting type SimpleText text Remove unused Java imports type SimpleText code spotless json type InlinedCode text Code Formatting type SimpleText text JSON JSON5 formatting type SimpleText code spotless markdown type InlinedCode text Code Formatting type SimpleText text Markdown formatting type SimpleText code spotless pom type InlinedCode text Code Formatting type SimpleText text POM file formatting and sorting type SimpleText code spotless prettier java type InlinedCode text Code Formatting type SimpleText text Prettier formatting for Java type SimpleText code spotless prettier java sort imports type InlinedCode text Code Formatting type SimpleText text Prettier import sorting type SimpleText code spotless sql type InlinedCode text Code Formatting type SimpleText text SQL formatting with Prettier type SimpleText code spotless yaml type InlinedCode text Code Formatting type SimpleText text YAML formatting type SimpleText type StrongEmphasis content text Code Refactoring type SimpleText code rewrite maven plugin type InlinedCode text Code Refactoring type SimpleText text Safe refactoring recipes type SimpleText code rewrite maven plugin dryRun type InlinedCode text Code Refactoring type SimpleText text Verify refactors without applying type SimpleText code rewrite maven plugin one off type InlinedCode text Code Refactoring type SimpleText text Potentially breaking refactors type SimpleText type StrongEmphasis content text Dependency Management type SimpleText code maven dependency plugin type InlinedCode text Dependency Management type SimpleText text Analyze dependencies type SimpleText code maven enforcer plugin type InlinedCode text Dependency Management type SimpleText text Enforce dependency rules type SimpleText type StrongEmphasis content text Static Analysis type SimpleText code checkstyle formatting type InlinedCode text Static Analysis type SimpleText text Code formatting checks type SimpleText code checkstyle formatting strict type InlinedCode text Static Analysis type SimpleText text Strict formatting checks type SimpleText code checkstyle semantics type InlinedCode text Static Analysis type SimpleText text Semantic code style checks type SimpleText code checkstyle semantics strict type InlinedCode text Static Analysis type SimpleText text Strict semantic checks type SimpleText code errorprone type InlinedCode text Static Analysis type SimpleText text Basic error prone checks type SimpleText code errorprone patch type InlinedCode text Static Analysis type SimpleText text Generate patches for error prone fixes type SimpleText code errorprone strict type InlinedCode text Static Analysis type SimpleText text Strict error prone checks type SimpleText code spotbugs maven plugin type InlinedCode text Static Analysis type SimpleText text FindBugs successor for bug detection type SimpleText type StrongEmphasis content text Testing & Coverage type SimpleText code jacoco maven plugin type InlinedCode text Testing & Coverage type SimpleText text Code coverage with JaCoCo type SimpleText code rerecord type InlinedCode text Testing & Coverage type SimpleText text Re record test snapshots type SimpleText type StrongEmphasis content text Utility type SimpleText code deploy type InlinedCode text Utility type SimpleText text Deploy artifacts with sources type SimpleText code spotless preserve cache type InlinedCode text Utility type SimpleText text Preserve Spotless cache during clean type SimpleText For detailed profile configurations see liftwizard profile parent pom xml on GitHub liftwizard profile parent liftwizard profile parent <parent> <groupId>io liftwizard< groupId> <artifactId>liftwizard profile parent< artifactId> <version>$ liftwizard version < version> < parent> # Format Java code mvn spotless apply activate profiles spotless apply spotless java spotless prettier java sort imports # Run static analysis mvn verify activate profiles errorprone strict on pull_request merge_group jobs maven test runs on ubuntu latest steps uses actions checkout@v4 uses jdx mise action@v2 run mvn verify maven errorprone strict runs on ubuntu latest steps uses actions checkout@v4 uses jdx mise action@v2 run mvn verify activate profiles errorprone strict DskipTests checkstyle semantics runs on ubuntu latest steps uses actions checkout@v4 uses jdx mise action@v2 run mvn checkstyle check activate profiles checkstyle semantics spotless java runs on ubuntu latest steps uses actions checkout@v4 uses jdx mise action@v2 run mvn spotless check activate profiles spotless check spotless java spotless prettier java sort imports all checks name All checks if $ cancelled needs maven test maven errorprone strict checkstyle semantics spotless java runs on ubuntu latest steps uses re actors alls green@release v1 with jobs $ toJSON needs on pull_request jobs spotless java fix runs on ubuntu latest permissions contents write steps uses actions checkout@v4 with ref $ github event pull_request head ref token $ secrets GITHUB_TOKEN uses jdx mise action@v2 name Configure Git run | git config global user name GitHub Actions git config global user email github actions@github com name Run Spotless Apply and commit changes run | mvn spotless apply activate profiles spotless apply spotless java spotless prettier java sort imports if n $ git status porcelain then FIX_BRANCH fix $ github event pull_request number spotless java git switch create $FIX_BRANCH git add all git commit message Auto fix Apply Spotless Java formatting git push force origin $FIX_BRANCH echo Fixes pushed to $FIX_BRANCH branch exit 1 fi