111-java-maven-dependencies — скилл для Claude Code: зависимости Maven
Добавляет в pom.xml зависимости для качества кода: JSpecify, Error Prone с NullAway, VAVR, ArchUnit, JavaMoney. Спрашивает, что нужно, и ставит только выбранное.
npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a claude-codeЧто делает 111-java-maven-dependencies
Скилл ведёт диалог, а не правит pom.xml молча. Сначала он просит выбрать семейства зависимостей: JSpecify для аннотаций nullness в scope provided, Error Prone вместе с NullAway для проверки null на этапе компиляции, VAVR для функциональных типов Try/Either и неизменяемых коллекций, ArchUnit для тестов архитектуры в scope test, JavaMoney для денег и валют по JSR 354 с Moneta. Есть вариант «None» и «Other».
Дальше вопросы задаются по выбору. Если вы отметили Error Prone + NullAway, скилл спросит имя основного пакета проекта в точечной нотации — оно нужно, чтобы NullAway анализировал ваш код. Без JSpecify этот набор не ставится: скилл попросит добавить его, если в проекте нет своих аннотаций nullness. Ссылки на реализацию читаются только для выбранных семейств, остальные не трогаются.
Перед любыми изменениями скилл запускает ./mvnw validate или mvn validate. Если валидация падает, работа останавливается — сначала чините проект. Это разумно: правки в сломанном pom.xml потом трудно откатывать. В конце скилл перечисляет, что добавил и какие проверки стоит прогнать следом.
Какие задачи решает
- добавить аннотации nullness JSpecify в scope
provided - включить Error Prone и NullAway с проверкой null на компиляции
- подключить VAVR для Try/Either и неизменяемых коллекций
- настроить ArchUnit для проверки правил архитектуры в тестах
- добавить JavaMoney для точных расчётов с деньгами и валютами
Примеры запросов агенту
- Добавь в проект Maven-зависимости для качества кода, сначала спроси, какие семейства мне нужны
- Подключи JSpecify и Error Prone с NullAway, основной пакет
com.example.myproject - Добавь ArchUnit в scope
testи JavaMoney для работы с деньгами
Как установить 111-java-maven-dependencies
1Через Skills CLI (Vercel)
npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a claude-code2Вручную: положить файлы
~/.claude/skills/111-java-maven-dependencies/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/111-java-maven-dependencies/
1Через Skills CLI (Vercel)
npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a codex2Вручную: положить файлы
.agents/skills/111-java-maven-dependencies/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a cursor2Вручную: положить файлы
.cursor/skills/111-java-maven-dependencies/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install jabrena/plinth 111-java-maven-dependencies2Вручную: положить файлы
.github/skills/111-java-maven-dependencies/SKILL.md1Через Skills CLI (Vercel)
npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a gemini-cli2Командой платформы
gemini skills install https://github.com/jabrena/plinth --path skills/111-java-maven-dependenciesВручную: положить файлы
.devin/skills/111-java-maven-dependencies/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о 111-java-maven-dependencies
Как установить 111-java-maven-dependencies в Claude?
Выполните npx skills add jabrena/plinth --skill 111-java-maven-dependencies -a claude-code. После этого файл скилла появится по пути ~/.claude/skills/111-java-maven-dependencies/SKILL.md.
Что делает 111-java-maven-dependencies?
Проводит опрос по зависимостям Maven для качества кода и доменного моделирования, а затем добавляет в pom.xml только выбранные семейства: JSpecify, Error Prone + NullAway, VAVR, ArchUnit, JavaMoney.
Что нужно для работы скилла?
Проект должен проходить ./mvnw validate или mvn validate — иначе скилл останавливается. Для Error Prone + NullAway понадобится имя основного пакета в точечной нотации и JSpecify, если своих аннотаций nullness в проекте нет.
Исходный текст
SKILL.md · Apache-2.0
--- name: 111-java-maven-dependencies description: Use when you need to add or evaluate Maven dependencies that improve code quality or domain modeling — including nullness annotations (JSpecify), static analysis (Error Prone + NullAway), functional programming (VAVR), architecture testing (ArchUnit), or money and currency support (JavaMoney) — and want a consultative, question-driven approach that adds only what you actually need. This should trigger for requests such as Add Maven dependencies; Add JSpecify nullness dependencies; Add Error Prone NullAway dependencies; Add VAVR functional dependencies; Add ArchUnit architecture testing dependencies; Add JavaMoney dependencies. Part of Plinth Toolkit license: Apache-2.0 metadata: author: Juan Antonio Breña Moral version: 0.19.0 --- # Add Maven dependencies for improved code quality Add essential Maven dependencies that enhance code quality, safety, and domain modeling through a consultative, question-driven approach. **This is an interactive SKILL**. **What is covered in this Skill?** - JSpecify: (nullness annotations, `provided` scope) - Error Prone + NullAway: (enhanced static analysis with compile-time null checking) - VAVR: (functional programming with Try/Either and immutable collections) - ArchUnit: (architecture rule enforcement, `test` scope) - JavaMoney: (Money and Currency API support with JSR 354 and Moneta) ## Constraints Before adding Maven dependencies, ensure the project is in a valid state. Use a consultative, question-driven flow that adds only what the user selects. - **MANDATORY**: Run `./mvnw validate` or `mvn validate` before any changes - **SAFETY**: If validation fails, stop and ask the user to fix issues—do not proceed until resolved - **BEFORE READING DEPENDENCY REFERENCES**: Run the question flow embedded in this SKILL.md first. Ask one consolidated dependency-selection question, then ask only conditional follow-up questions required by the selected options. Read only the dependency references selected by the user's answers. Use consultative language, present trade-offs, and wait for user responses before implementing ## When to use this skill - Add Maven dependencies - Add JSpecify nullness dependencies - Add Error Prone NullAway dependencies - Add VAVR functional dependencies - Add ArchUnit architecture testing dependencies - Add JavaMoney dependencies ## Workflow 1. **Validate project before changes** Run `./mvnw validate` or `mvn validate` and stop if validation fails. 2. **Ask dependency assessment questions before reading references** Run this XML-included question flow before reading any dependency implementation reference. Ask the consolidated dependency-selection question first, wait for the user's answer, and record selected dependency families before continuing. Ask conditional follow-up questions only when required by the selected dependencies. **Question 1**: Which code-quality dependencies do you want to add? Options: - JSpecify (modern nullness annotations, `provided` scope; recommended for new projects) - Error Prone + NullAway (enhanced compiler analysis and compile-time nullness checking; requires JSpecify) - VAVR (functional programming support with Try/Either and immutable collections) - ArchUnit (architecture testing with JUnit 5, `test` scope) - JavaMoney (Money and Currency API support with JSR 354 and Moneta) - None - Other (specify) **Recommendation**: Select JSpecify for better null-safety annotations. Add Error Prone + NullAway when you want stronger compile-time analysis. Add VAVR only when functional programming patterns are useful for the project. Add ArchUnit when you want automated architecture governance. Add JavaMoney when the domain needs explicit monetary amounts, currencies, formatting, conversion, or precision-safe money calculations. **Selection notes**: - If Error Prone + NullAway is selected, also select JSpecify unless the project already has equivalent nullness annotations configured. - If None is selected, do not add dependency-family references. --- **Question 2** (conditional): What is your main project package name? **Note**: This question is asked only if Error Prone + NullAway was selected. This is needed to configure NullAway to analyze your code. For example, if your classes are in `com.example.myproject`, enter `com.example.myproject`. **Format**: Use dot notation (e.g., `com.example.myproject` or `org.mycompany.myapp`) **Example**: `com.example.myproject` After all applicable questions are answered, confirm the selections and map them to references: - If JSpecify is selected, read `references/111-java-maven-dependencies-jspecify.md`. - If enhanced compiler analysis is selected, use the Error Prone + NullAway section from `references/111-java-maven-dependencies-jspecify.md`. - If VAVR is selected, read `references/111-java-maven-dependencies-vavr.md`. - If ArchUnit is selected, read `references/111-java-maven-dependencies-archunit.md`. - If JavaMoney is selected, read `references/111-java-maven-dependencies-javamoney.md`. - Do not read or apply unselected dependency-family references. 3. **Read selected references and add only selected dependencies** Read only the selected dependency-family references, then implement only the dependencies, properties, scopes, plugin configuration, and support files chosen by the user while preserving the existing `pom.xml` structure. 4. **Report trade-offs and next checks** Summarize what was added, why, and any recommended follow-up validations or tooling alignment. ## Reference For detailed guidance, examples, and constraints, see: - [references/111-java-maven-dependencies-jspecify.md](references/111-java-maven-dependencies-jspecify.md) - [references/111-java-maven-dependencies-vavr.md](references/111-java-maven-dependencies-vavr.md) - [references/111-java-maven-dependencies-archunit.md](references/111-java-maven-dependencies-archunit.md) - [references/111-java-maven-dependencies-javamoney.md](references/111-java-maven-dependencies-javamoney.md)
© Juan Antonio Breña Moral · Apache-2.0 · jabrena/plinth