# Maven Build

> Build and test the Morphia project using Maven. Use when compiling, running tests, or building artifacts. Use when this capability is needed.

- Skill: `tomevault-io/maven-build` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/maven-build`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/maven-build/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/maven-build

---


# Maven Build Commands

This is a multi-module Maven project. Use `mvn` or `./mvnw` (if available) to build and test.

## Common Commands

- **Compile**: `mvn clean compile`
- **Run tests**: `mvn test`
- **Run specific test**: `mvn test -Dtest=ClassName#methodName`
- **Integration tests**: `mvn clean verify`
- **Full build (skip tests)**: `mvn clean install -DskipTests`
- **Full build**: `mvn clean install`

## Module-Specific Builds

To build or test a specific module:
```
mvn -pl module-name test
mvn -pl module-name -am clean install
```

The `-am` flag builds required dependencies.

## Guidelines

- Prefer `./mvnw` if the wrapper exists in the project root
- Always run tests after making code changes to verify nothing broke
- If tests fail, analyze the error output and suggest fixes
- Use `-DskipTests` only when explicitly requested or for quick compile checks

---
> Source: [MorphiaOrg/morphia](https://github.com/MorphiaOrg/morphia) — distributed by [TomeVault](https://tomevault.io).
<!-- tomevault:4.0:skill_md:2026-06-21 -->

