From b8c978e4aacd3bffe0ee274bb342a0cf64e3237e Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 16 Jul 2026 08:21:42 +0000 Subject: [PATCH] Remove the relocation stub from the active reactor + repo-wide URL cleanup The relocation stub (net.ladenthin:llamacpp-ai-index-maven-plugin) was published once at 1.0.4 as part of the 1.1.1 release, and the redirect was verified working end-to-end: a Maven resolution of the old coordinates from a completely clean local repository correctly follows the relocation through to srcmorph-maven-plugin:1.1.1 and its full dependency graph. The published artifact is permanent on Maven Central regardless of this repo's module list, and it will never need another release, so there's no reason to keep carrying it (and the `versions:set -Dexcludes=...` footgun it required) in active development. - Removed llamacpp-ai-index-maven-plugin/ and its entry from the root pom. - Updated CLAUDE.md, README.md, TODO.md, CHANGELOG.md, docs/RELEASE.md, srcmorph-maven-plugin/README.md to reflect the 3-module reactor and the stub's now-historical status; removed the now-moot versions:set exclusion caveat from TODO.md and CLAUDE.md. - .github/workflows/publish.yml comment updated (no functional change needed - the stub never produced a jar, so no per-module CI step ever referenced it beyond the aggregate reactor build). - Fixed a real staleness bug found along the way: srcmorph's own spotbugs-exclude.xml comments still called the sibling plugin module by its pre-rename name ("llamacpp-ai-index-maven-plugin module") instead of "srcmorph-maven-plugin module" - missed during the original Step 9 rename. - Repo-wide GitHub link cleanup: renamed bernardladenthin/llamacpp-ai-index-maven-plugin URLs to the canonical bernardladenthin/srcmorph in README.md, CONTRIBUTING.md, SECURITY.md, SUPPORT.md, .github/ISSUE_TEMPLATE/config.yml, and REUSE.toml's package metadata. Left third-party service-specific identifiers untouched (SonarCloud project key, Snyk/FOSSA/Libraries.io/ Scorecard/REUSE.software badges) since those may be registered under the old name independently of the GitHub repo and I can't verify whether they were updated. Updated the README's Maven Central + Snapshot badges to point at srcmorph-maven-plugin (the real, current plugin artifact) instead of the now-deprecated stub coordinates. Verified: mvn clean verify - BUILD SUCCESS. Reactor build order confirmed as 4 projects (parent + 3 real modules), no stub. --- .github/ISSUE_TEMPLATE/config.yml | 4 +- .github/workflows/publish.yml | 8 +-- CHANGELOG.md | 21 +++++-- CLAUDE.md | 79 +++++++++++++------------- CONTRIBUTING.md | 10 ++-- README.md | 46 ++++++++------- REUSE.toml | 4 +- SECURITY.md | 2 +- SUPPORT.md | 4 +- TODO.md | 13 ----- docs/RELEASE.md | 32 ++++++++++- llamacpp-ai-index-maven-plugin/pom.xml | 72 ----------------------- pom.xml | 23 ++++---- srcmorph-maven-plugin/README.md | 8 +-- srcmorph/spotbugs-exclude.xml | 14 ++--- 15 files changed, 147 insertions(+), 193 deletions(-) delete mode 100644 llamacpp-ai-index-maven-plugin/pom.xml diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index ffc4030..10ffa0b 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -5,8 +5,8 @@ blank_issues_enabled: false contact_links: - name: Security vulnerability - url: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/security/advisories/new + url: https://github.com/bernardladenthin/srcmorph/security/advisories/new about: Report a security issue privately via GitHub's vulnerability reporting. - name: Question or general discussion - url: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/discussions + url: https://github.com/bernardladenthin/srcmorph/discussions about: Ask questions and discuss with the community. If Discussions are not enabled, open an issue with the 'question' label. diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 30fb664..720f8ae 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -257,11 +257,11 @@ jobs: - uses: actions/upload-artifact@v7 with: name: plugin-jars - # All three reactor modules now produce their own jars: srcmorph (core library), + # All three reactor modules produce their own jars: srcmorph (core library), # srcmorph-cli (includes the jar-with-dependencies fat jar — the CLI's deliverable), - # and srcmorph-maven-plugin (the Maven plugin, renamed from llamacpp-ai-index-maven-plugin; - # the retired coordinates now live only in the pom-only relocation-stub module, which - # produces no jar). + # and srcmorph-maven-plugin (the Maven plugin, renamed from llamacpp-ai-index-maven-plugin + # in the migration). The former 4th module — a pom-only relocation-stub for the retired + # coordinates — was published once and then removed from this reactor; see CLAUDE.md. path: | srcmorph/target/*.jar srcmorph-cli/target/*.jar diff --git a/CHANGELOG.md b/CHANGELOG.md index de7b33a..50b779a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,17 @@ The release procedure (prompt template and step-by-step instructions) lives in [ ## [Unreleased] +### Removed +- **Relocation-stub module** (`llamacpp-ai-index-maven-plugin/`, `net.ladenthin:llamacpp-ai-index-maven-plugin`) + removed from the active reactor. It was published once at `1.0.4` as part of the `1.1.1` release + and the redirect verified working end-to-end (a clean-environment Maven resolution of the old + coordinates correctly follows the relocation through to `srcmorph-maven-plugin:1.1.1` and its + full dependency graph). The published `1.0.4` artifact is permanent on Maven Central regardless + of this repo's module list and will never need another release, so there is no reason to keep + carrying the module (and the `versions:set -Dexcludes=...` caveat it required) in ongoing + development. `.github/workflows/publish.yml` updated accordingly (no more per-module handling for + a fourth artifact). + ## [1.1.1] - 2026-07-15 ### Added @@ -119,8 +130,8 @@ First public release on Maven Central. Pre-OpenSSF history themes (March–May 2 --- -[Unreleased]: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/compare/v1.1.1...HEAD -[1.1.1]: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/compare/v1.0.2...v1.1.1 -[1.0.2]: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/compare/v1.0.1...v1.0.2 -[1.0.1]: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/compare/v1.0.0...v1.0.1 -[1.0.0]: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/releases/tag/v1.0.0 +[Unreleased]: https://github.com/bernardladenthin/srcmorph/compare/v1.1.1...HEAD +[1.1.1]: https://github.com/bernardladenthin/srcmorph/compare/v1.0.2...v1.1.1 +[1.0.2]: https://github.com/bernardladenthin/srcmorph/compare/v1.0.1...v1.0.2 +[1.0.1]: https://github.com/bernardladenthin/srcmorph/compare/v1.0.0...v1.0.1 +[1.0.0]: https://github.com/bernardladenthin/srcmorph/releases/tag/v1.0.0 diff --git a/CLAUDE.md b/CLAUDE.md index 4fd6f64..87277a5 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -12,26 +12,33 @@ layered output — per-file, then per-package, then per-project. Today it emits Markdown summaries for AI-assisted code navigation; the same rule-routed pipeline is generic enough to eventually emit wikis, architecture docs, diagrams, or source-to-source transformations. -**This repository completed its migration to a 4-module Maven reactor.** It started as a single +**This repository completed its migration to a 3-module Maven reactor.** It started as a single Maven plugin (`net.ladenthin:llamacpp-ai-index-maven-plugin`) and was restructured into: a -framework-free core library, a standalone CLI, the original plugin (now a thin wrapper around the -library, **renamed** to `net.ladenthin:srcmorph-maven-plugin`), and a tiny relocation-stub module -that keeps the old `net.ladenthin:llamacpp-ai-index-maven-plugin` coordinates alive on Maven -Central purely as a `` pointer. **The plugin rename is done**: +framework-free core library, a standalone CLI, and the original plugin (now a thin wrapper around +the library, **renamed** to `net.ladenthin:srcmorph-maven-plugin`). **The plugin rename is done**: coordinates, package, goal prefix, and every `@Parameter` property changed in this step — do not write `aiIndex.*` properties, the `ai-index` goal prefix, or the `net.ladenthin.maven.llamacpp.aiindex` package in new documentation or code; use `srcmorph.*`, `srcmorph`, and `net.ladenthin.maven.srcmorph.mojo` instead (see the plugin module's own section -below). The `1.1.1` reactor release and the `1.0.4` relocation stub were published to Maven -Central; development on `main` now continues at the next SNAPSHOT version. +below). The `1.1.1` reactor release was published to Maven Central; development on `main` now +continues at the next SNAPSHOT version. + +**A fourth module existed temporarily**: a tiny relocation-stub POM +(`net.ladenthin:llamacpp-ai-index-maven-plugin`, pinned at `1.0.4`, only a +`` pointing at `srcmorph-maven-plugin:1.1.1`) so existing +consumers of the old coordinates get transparently redirected. It was published once, verified +working end-to-end (a clean-environment Maven resolution of the old coordinates correctly followed +the relocation through to the real artifact and its full dependency graph), and then **removed from +this reactor** — the published `1.0.4` artifact is permanent on Maven Central regardless of what +this repo's module list contains, and it will never need another release, so there was no reason to +keep carrying it (and its `versions:set` exclusion footgun) in active development. - **Group ID:** `net.ladenthin` - **Java:** target bytecode 1.8 (production code), Java 21 test sources, built with JDK 21 - **License:** Apache 2.0 - **Author:** Bernard Ladenthin (Copyright 2026) - **Reactor version:** `1.2.0-SNAPSHOT` (single shared version across `srcmorph`, `srcmorph-cli`, - and `srcmorph-maven-plugin`; the relocation stub below is version-pinned independently). Last - released version: `1.1.1`. + and `srcmorph-maven-plugin`). Last released version: `1.1.1`. --- @@ -55,25 +62,16 @@ llamacpp-ai-index-maven-plugin/ (repo root; reactor parent) │ └── configuration/ CConfiguration + CCommand (BAF public-field style) ├── srcmorph-maven-plugin/ Maven plugin net.ladenthin:srcmorph-maven-plugin, goalPrefix srcmorph │ └── src/main/java/net/ladenthin/maven/srcmorph/mojo/ (5 mojos; renamed package/properties) -├── llamacpp-ai-index-maven-plugin/ RELOCATION STUB net.ladenthin:llamacpp-ai-index-maven-plugin:1.0.4 -│ └── pom.xml only — no source, no ├── examples/ config_*.json/.yaml + run_*.sh/.bat + logbackConfiguration.xml ├── docs/ RELEASE.md + the ai-index model-benchmark writeups -└── .github/workflows/ CI adapted to the 4-module reactor +└── .github/workflows/ CI adapted to the 3-module reactor ``` -Every module except the relocation stub inherits its `` from the parent -(`net.ladenthin:srcmorph-parent`), so `srcmorph`/`srcmorph-cli`/`srcmorph-maven-plugin` ship in -lockstep by construction. Bump their version reactor-wide with -`mvn versions:set -DnewVersion=X -DgenerateBackupPoms=false` from the repo root — but the relocation -stub (`llamacpp-ai-index-maven-plugin/`) has **no ``** and is version-pinned independently -at `1.0.4`; because it is still listed in the root ``, a plain `versions:set` run from the -root walks it too and would overwrite that pin unless excluded: - -```bash -mvn versions:set -DnewVersion=X -DgenerateBackupPoms=false \ - -Dexcludes=net.ladenthin:llamacpp-ai-index-maven-plugin -``` +Every module inherits its `` from the parent (`net.ladenthin:srcmorph-parent`), so +`srcmorph`/`srcmorph-cli`/`srcmorph-maven-plugin` ship in lockstep by construction. Bump their +version reactor-wide with `mvn versions:set -DnewVersion=X -DgenerateBackupPoms=false` from the +repo root — no exclusions needed today (the relocation-stub module that once required one was +removed after its `1.0.4` release; see "Project Overview" above). ### `srcmorph` — the core library @@ -178,8 +176,8 @@ CLI driven by a single JSON or YAML configuration file: `net.ladenthin.maven.llamacpp.aiindex.mojo`), goal prefix `srcmorph` (was `ai-index`), every `@Parameter` property now spelled `srcmorph.*` (e.g. `srcmorph.skip`, `srcmorph.file.skip`, `srcmorph.planOnly`, `srcmorph.generationProvider`, `srcmorph.llama.modelPath` — was `aiIndex.*`). -The old coordinates are kept alive only via the separate relocation-stub module (see "Repository -layout" above and its own paragraph below) — never describe the plugin using the old +The old coordinates were kept alive on Maven Central via a one-time relocation-stub publish (see +"Project Overview" above and its own paragraph below) — never describe the plugin using the old coordinates/package/properties in new documentation or code. The plugin's *contents* stay thin: it depends on `net.ladenthin:srcmorph` (compile scope) for everything except the 5 mojo classes themselves. @@ -204,17 +202,19 @@ themselves. `srcmorph` — they were not relocated during the core extraction. - Full goal/parameter reference: `srcmorph-maven-plugin/README.md`. -### `llamacpp-ai-index-maven-plugin` — the relocation stub (retired coordinates) +### `llamacpp-ai-index-maven-plugin` — the retired relocation stub (no longer in this repo) -A separate, minimal 4th reactor module — **not** a renamed copy of the plugin above, and not a -child of `srcmorph-parent` (no `` at all). Its entire `pom.xml` is `groupId` + -`artifactId` (`llamacpp-ai-index-maven-plugin`) + a version pinned independently at `1.0.4` + -`` pointing at `net.ladenthin:srcmorph-maven-plugin:1.1.1`. -No source, no tests, no dependencies. Its sole purpose is so a consumer still declaring the old -Maven coordinates gets redirected by Maven to the renamed plugin once both are published. Because -it is still listed in the root `` for aggregation, a reactor-wide `mvn versions:set` run -from the repo root must exclude it explicitly — see "Repository layout" above for the exact -command; the same warning is repeated in the stub's own `pom.xml` comment and in `TODO.md`. +Not a module in this reactor anymore. It existed briefly as a minimal 4th reactor module — **not** +a renamed copy of the plugin above, and not a child of `srcmorph-parent` (no `` at all). +Its entire `pom.xml` was `groupId` + `artifactId` (`llamacpp-ai-index-maven-plugin`) + a version +pinned independently at `1.0.4` + `` pointing at +`net.ladenthin:srcmorph-maven-plugin:1.1.1`. No source, no tests, no dependencies. Its sole purpose +was so a consumer still declaring the old Maven coordinates gets redirected by Maven to the renamed +plugin — published once, verified working end-to-end from a clean environment, then removed from +active development: the published `1.0.4` artifact is permanent on Maven Central regardless of +this repo's module list, and it will never need another release. Anyone still depending on the old +coordinates continues to be redirected correctly; nothing here needs to change again for that to +keep working. --- @@ -225,9 +225,8 @@ command; the same warning is repeated in the stub's own `pom.xml` comment and in ```bash mvn compile # Compiles every module (Java + generates nothing native; pure Java reactor) mvn test # Runs every module's tests -mvn package # Builds all five reactor projects: parent pom + 3 jars (incl. the CLI's fat - # jar) + the relocation-stub pom (trivial — no source, packaging=pom) -mvn install # Installs all five into ~/.m2 (needed before iterating on a single module — see below) +mvn package # Builds all four reactor projects: parent pom + 3 jars (incl. the CLI's fat jar) +mvn install # Installs all four into ~/.m2 (needed before iterating on a single module — see below) ``` ### Iterating on one module @@ -281,7 +280,7 @@ is unavailable. - `srcmorph-cli` — `MainTest`, `ConfigBindingTest`, `ExamplesConfigBindingTest`, `CliArchitectureTest`, `CliEndToEndTest`. - `srcmorph-maven-plugin` — `PluginArchitectureTest`, `MojoPhaseSkipTest`, plus the jcstress/ - vmlens tests noted above. (The `llamacpp-ai-index-maven-plugin` relocation stub has no tests.) + vmlens tests noted above. See `TEST_WRITING_GUIDE.md` (repo root, applies to every module) for full conventions. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index d446106..293283c 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,6 +1,6 @@ -# Contributing to llamacpp-ai-index-maven-plugin +# Contributing to srcmorph -Thank you for your interest in contributing to **llamacpp-ai-index-maven-plugin**, a free Maven plugin for generating AI-readable hierarchical documentation of Java source projects using local llama.cpp-compatible models. +Thank you for your interest in contributing to **srcmorph**, a prompt-driven source-tree transformer for generating AI-readable hierarchical documentation of Java source projects using local llama.cpp-compatible models. --- @@ -54,7 +54,7 @@ mvn package -o -DskipTests Please use the GitHub issue tracker: -https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/issues +https://github.com/bernardladenthin/srcmorph/issues When filing a bug report, include: - Java version (`java -version`) and Maven version (`mvn -version`) @@ -139,9 +139,9 @@ docs(security): publish maintainer fallback email ## Communication channels - **GitHub Issues** — bug reports, feature requests, and questions: - https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/issues + https://github.com/bernardladenthin/srcmorph/issues - **GitHub Security Advisories** — private vulnerability reports: - https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/security/advisories/new + https://github.com/bernardladenthin/srcmorph/security/advisories/new --- diff --git a/README.md b/README.md index 3c92129..f76a969 100644 --- a/README.md +++ b/README.md @@ -21,14 +21,14 @@ [![Lincheck](https://img.shields.io/badge/tested%20with-Lincheck-7F52FF)](https://github.com/JetBrains/lincheck) [![vmlens](https://img.shields.io/badge/tested%20with-vmlens-ff6f00)](https://vmlens.com) [![JMH](https://img.shields.io/badge/benchmarked%20with-JMH-25A162)](https://openjdk.org/projects/code-tools/jmh/) -[![Publish](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/publish.yml/badge.svg)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/publish.yml) -[![CodeQL](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/codeql.yml/badge.svg)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/codeql.yml) +[![Publish](https://github.com/bernardladenthin/srcmorph/actions/workflows/publish.yml/badge.svg)](https://github.com/bernardladenthin/srcmorph/actions/workflows/publish.yml) +[![CodeQL](https://github.com/bernardladenthin/srcmorph/actions/workflows/codeql.yml/badge.svg)](https://github.com/bernardladenthin/srcmorph/actions/workflows/codeql.yml) **Coverage:** [![Coverage Status](https://coveralls.io/repos/github/bernardladenthin/llamacpp-ai-index-maven-plugin/badge.svg?branch=main)](https://coveralls.io/github/bernardladenthin/llamacpp-ai-index-maven-plugin?branch=main) [![codecov](https://codecov.io/gh/bernardladenthin/llamacpp-ai-index-maven-plugin/graph/badge.svg)](https://codecov.io/gh/bernardladenthin/llamacpp-ai-index-maven-plugin) [![JaCoCo](https://img.shields.io/codecov/c/github/bernardladenthin/llamacpp-ai-index-maven-plugin?label=JaCoCo&logo=java)](https://codecov.io/gh/bernardladenthin/llamacpp-ai-index-maven-plugin) -[![PIT Mutation](https://img.shields.io/badge/PIT%20mutation-100%25%20(47%20classes)-brightgreen)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/publish.yml) +[![PIT Mutation](https://img.shields.io/badge/PIT%20mutation-100%25%20(47%20classes)-brightgreen)](https://github.com/bernardladenthin/srcmorph/actions/workflows/publish.yml) **Quality:** [![Quality Gate](https://sonarcloud.io/api/project_badges/measure?project=bernardladenthin_llamacpp-ai-index-maven-plugin&metric=alert_status)](https://sonarcloud.io/dashboard?id=bernardladenthin_llamacpp-ai-index-maven-plugin) @@ -39,20 +39,20 @@ [![Known Vulnerabilities](https://snyk.io/test/github/bernardladenthin/llamacpp-ai-index-maven-plugin/badge.svg?targetFile=pom.xml)](https://snyk.io/test/github/bernardladenthin/llamacpp-ai-index-maven-plugin?targetFile=pom.xml) [![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fbernardladenthin%2Fllamacpp-ai-index-maven-plugin.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fbernardladenthin%2Fllamacpp-ai-index-maven-plugin?ref=badge_shield) [![Dependencies](https://img.shields.io/librariesio/github/bernardladenthin/llamacpp-ai-index-maven-plugin)](https://libraries.io/github/bernardladenthin/llamacpp-ai-index-maven-plugin) -[![OSV-Scanner](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/osv-scanner.yml/badge.svg)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/actions/workflows/osv-scanner.yml) +[![OSV-Scanner](https://github.com/bernardladenthin/srcmorph/actions/workflows/osv-scanner.yml/badge.svg)](https://github.com/bernardladenthin/srcmorph/actions/workflows/osv-scanner.yml) **Package:** -[![Maven Central](https://img.shields.io/maven-central/v/net.ladenthin/llamacpp-ai-index-maven-plugin)](https://central.sonatype.com/artifact/net.ladenthin/llamacpp-ai-index-maven-plugin) -[![Snapshot](https://img.shields.io/badge/snapshot-latest-informational)](https://central.sonatype.com/repository/maven-snapshots/net/ladenthin/llamacpp-ai-index-maven-plugin/) -![Release Date](https://img.shields.io/github/release-date/bernardladenthin/llamacpp-ai-index-maven-plugin) -![Last Commit](https://img.shields.io/github/last-commit/bernardladenthin/llamacpp-ai-index-maven-plugin) +[![Maven Central](https://img.shields.io/maven-central/v/net.ladenthin/srcmorph-maven-plugin)](https://central.sonatype.com/artifact/net.ladenthin/srcmorph-maven-plugin) +[![Snapshot](https://img.shields.io/badge/snapshot-latest-informational)](https://central.sonatype.com/repository/maven-snapshots/net/ladenthin/srcmorph-maven-plugin/) +![Release Date](https://img.shields.io/github/release-date/bernardladenthin/srcmorph) +![Last Commit](https://img.shields.io/github/last-commit/bernardladenthin/srcmorph) **License:** [![License](https://img.shields.io/badge/License-Apache%202.0-orange)](./LICENSE) **Community:** [![OpenSSF Best Practices](https://www.bestpractices.dev/projects/12863/badge)](https://www.bestpractices.dev/projects/12863) -[![Contribute with Gitpod](https://img.shields.io/badge/Contribute%20with-Gitpod-908a85?logo=gitpod)](https://gitpod.io/#https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin) +[![Contribute with Gitpod](https://img.shields.io/badge/Contribute%20with-Gitpod-908a85?logo=gitpod)](https://gitpod.io/#https://github.com/bernardladenthin/srcmorph) [![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/badge)](https://scorecard.dev/viewer/?uri=github.com/bernardladenthin/llamacpp-ai-index-maven-plugin) [![Dependabot](https://img.shields.io/badge/Dependabot-enabled-success?logo=dependabot)](./.github/dependabot.yml) [![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg)](https://www.conventionalcommits.org/en/v1.0.0/) @@ -60,9 +60,9 @@ [![SemVer](https://img.shields.io/badge/SemVer-2.0.0-blue)](https://semver.org/spec/v2.0.0.html) [![REUSE](https://api.reuse.software/badge/github.com/bernardladenthin/llamacpp-ai-index-maven-plugin)](https://api.reuse.software/info/github.com/bernardladenthin/llamacpp-ai-index-maven-plugin) [![Maintained?](https://isitmaintained.com/badge/resolution/bernardladenthin/llamacpp-ai-index-maven-plugin.svg)](https://isitmaintained.com/project/bernardladenthin/llamacpp-ai-index-maven-plugin) -[![Issues](https://img.shields.io/github/issues/bernardladenthin/llamacpp-ai-index-maven-plugin)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/issues) -[![Pull Requests](https://img.shields.io/github/issues-pr/bernardladenthin/llamacpp-ai-index-maven-plugin)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/pulls) -[![GitHub Stars](https://img.shields.io/github/stars/bernardladenthin/llamacpp-ai-index-maven-plugin?style=social)](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/stargazers) +[![Issues](https://img.shields.io/github/issues/bernardladenthin/srcmorph)](https://github.com/bernardladenthin/srcmorph/issues) +[![Pull Requests](https://img.shields.io/github/issues-pr/bernardladenthin/srcmorph)](https://github.com/bernardladenthin/srcmorph/pulls) +[![GitHub Stars](https://img.shields.io/github/stars/bernardladenthin/srcmorph?style=social)](https://github.com/bernardladenthin/srcmorph/stargazers) [![Treeware](https://img.shields.io/badge/dynamic/json?color=brightgreen&label=Treeware&query=%24.total&url=https%3A%2F%2Fpublic.offset.earth%2Fusers%2Ftreeware%2Ftrees)](https://treeware.earth) [![Stand With Ukraine](https://raw.githubusercontent.com/vshymanskyy/StandWithUkraine/main/badges/StandWithUkraine.svg)](https://stand-with-ukraine.pp.ua) @@ -77,14 +77,15 @@ model + prompt, oversize handling) is generic enough to eventually emit wikis, a diagrams, or even source-to-source transformations. > **Migration note.** This repository was restructured from a single Maven plugin into a reactor of -> four artifacts — see "Module overview" below. As part of that migration the Maven plugin was +> three artifacts — see "Module overview" below. As part of that migration the Maven plugin was > **renamed** from `net.ladenthin:llamacpp-ai-index-maven-plugin` to > `net.ladenthin:srcmorph-maven-plugin` (goal prefix `srcmorph`, properties `srcmorph.*`). Existing -> consumers who still declare the old coordinates are **not** broken: the old artifactId is -> published as a tiny relocation-stub POM (``) that redirects -> Maven to the new coordinates automatically — no consumer action required, though updating your own -> POM to the new coordinates directly is recommended. See [`CLAUDE.md`](CLAUDE.md) and -> [`TODO.md`](TODO.md) for the full migration status. +> consumers who still declare the old coordinates are **not** broken: the old artifactId was +> published once, at version `1.0.4`, as a tiny relocation-stub POM +> (``) that redirects Maven to the new coordinates +> automatically — verified working end-to-end from a clean environment. No consumer action is +> required, though updating your own POM to the new coordinates directly is recommended. See +> [`CLAUDE.md`](CLAUDE.md) for the full migration history. ## Module overview @@ -93,11 +94,12 @@ diagrams, or even source-to-source transformations. | [`srcmorph/`](srcmorph/README.md) | `net.ladenthin:srcmorph` | The core library: a framework-free Java API (no Maven dependency) — the shared `SrcMorphConfiguration` plus the `generate`/`aggregate-packages`/`aggregate-project`/`calibrate` engines. Use this to embed srcmorph in your own tooling. | | [`srcmorph-cli/`](srcmorph-cli/README.md) | `net.ladenthin:srcmorph-cli` | A standalone CLI driven by one JSON or YAML configuration file (ships as a `java -jar`-ready fat jar). No Maven project required. | | [`srcmorph-maven-plugin/`](srcmorph-maven-plugin/README.md) | `net.ladenthin:srcmorph-maven-plugin` | The Maven plugin, a thin wrapper around `srcmorph` — **renamed** from `net.ladenthin:llamacpp-ai-index-maven-plugin` (goal prefix `srcmorph`, was `ai-index`; properties `srcmorph.*`, were `aiIndex.*`). | -| [`llamacpp-ai-index-maven-plugin/`](llamacpp-ai-index-maven-plugin/pom.xml) | `net.ladenthin:llamacpp-ai-index-maven-plugin` (pinned at `1.0.4`) | A tiny relocation-stub POM — no source, no dependencies — that redirects Maven Central consumers of the old plugin coordinates to `srcmorph-maven-plugin`. | -The first three modules (plus the reactor parent pom) are released together from this one -repository at the same version; the relocation stub is versioned and published independently (see -`CLAUDE.md`). +All three modules (plus the reactor parent pom) are released together from this one repository at +the same version. (A fourth, independently-versioned relocation-stub module for the retired +`net.ladenthin:llamacpp-ai-index-maven-plugin` coordinates was part of this reactor through the +`1.1.1` release and has since been removed — its published `1.0.4` artifact remains permanently on +Maven Central regardless; see `CLAUDE.md`.) ## Quickstart diff --git a/REUSE.toml b/REUSE.toml index 85b73b0..0b3599f 100644 --- a/REUSE.toml +++ b/REUSE.toml @@ -1,7 +1,7 @@ version = 1 -SPDX-PackageName = "llamacpp-ai-index-maven-plugin" +SPDX-PackageName = "srcmorph" SPDX-PackageSupplier = "Bernard Ladenthin " -SPDX-PackageDownloadLocation = "https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin" +SPDX-PackageDownloadLocation = "https://github.com/bernardladenthin/srcmorph" [[annotations]] path = [ diff --git a/SECURITY.md b/SECURITY.md index fa2705c..f91de0b 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -18,7 +18,7 @@ The project has not yet cut a versioned release. Security fixes are applied dire Use GitHub's built-in private vulnerability reporting mechanism: -https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/security/advisories/new +https://github.com/bernardladenthin/srcmorph/security/advisories/new This creates a private advisory that only the maintainers can see. diff --git a/SUPPORT.md b/SUPPORT.md index f34eccc..3ebd3b2 100644 --- a/SUPPORT.md +++ b/SUPPORT.md @@ -2,9 +2,9 @@ If you need help with this project: -- **Bug reports / feature requests** — open an issue: https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/issues +- **Bug reports / feature requests** — open an issue: https://github.com/bernardladenthin/srcmorph/issues - **Security vulnerabilities** — please do **not** file public issues; see [SECURITY.md](./SECURITY.md) for the private reporting channel. -- **Questions / general discussion** — use [GitHub Discussions](https://github.com/bernardladenthin/llamacpp-ai-index-maven-plugin/discussions) if enabled, or open an issue and label it `question`. +- **Questions / general discussion** — use [GitHub Discussions](https://github.com/bernardladenthin/srcmorph/discussions) if enabled, or open an issue and label it `question`. For broader context, also see: diff --git a/TODO.md b/TODO.md index a623ddc..3a4538b 100644 --- a/TODO.md +++ b/TODO.md @@ -7,17 +7,6 @@ recorded in git history and `crossrepostatus.md`, not here. ## Open -- **Caveat — exclude the stub from reactor-wide version bumps.** Because the relocation stub is - listed in the root ``, a `mvn versions:set -DnewVersion=X -DgenerateBackupPoms=false` run - from the repo root walks every module reachable from that list — including the stub — and would - overwrite its frozen `1.0.4` unless explicitly excluded: - ```bash - mvn versions:set -DnewVersion=X -DgenerateBackupPoms=false \ - -Dexcludes=net.ladenthin:llamacpp-ai-index-maven-plugin - ``` - The same warning is documented in the stub's own `pom.xml` comment and in the root `CLAUDE.md` - reactor-layout section. - - **PIT mutation-testing gate for `srcmorph-cli` and the plugin module.** Only `srcmorph` (`srcmorph/pom.xml`) is PIT-gated today — `100` over an explicit `` list of 47 classes across config/document/engine/indexer/prompt/ @@ -46,5 +35,3 @@ recorded in git history and `crossrepostatus.md`, not here. - **Null-safety refinement.** JSpecify + NullAway are enforced at compile time in strict JSpecify mode in every module (see each module's own `pom.xml`); `@NullMarked` on the package; framework-populated POJOs carry class-level `@SuppressWarnings({"NullAway.Init","initialization.fields.uninitialized"})`. Open follow-up: review remaining unannotated public API surfaces for places where `@Nullable` would be more precise than the implicit non-null default. - **Cross-repo code-quality TODOs** — see [`../workspace/policies/code-quality-todos.md`](../workspace/policies/code-quality-todos.md) for the canonical `@VisibleForTesting` design-fit review, package hierarchy review, and class/method naming review. This repo has no `@VisibleForTesting` usages today; the package and naming reviews are still open here. - -- **SLF4J gap CLOSED (core + CLI).** `srcmorph`'s `indexer.*` classes (`SourceFileIndexer`, `PackageIndexer`, `ProjectIndexer`, `AiFieldGenerationSupport`) and `engine.*` classes all log via `org.slf4j.Logger` instead of a Maven `Log`; `srcmorph-cli`'s `Main` does the same. Only the plugin module's 5 mojos (and `PluginArchitectureTest`'s Maven-confinement rules) still touch the Maven Plugin API directly — that boundary is deliberate (see `CLAUDE.md`), not a gap. Maven's `maven-slf4j-provider` binds `slf4j-api` inside plugin executions, so every `LOGGER.info(...)`/`.warn(...)`/`.debug(...)` call in the delegated-to `srcmorph` code surfaces as a normal `[INFO]`/`[WARN]`/`[DEBUG]` line in `mvn` output with zero glue; the CLI ships its own logback binding for the same log lines outside Maven. `AiFieldGenerationSupportTest` (in `srcmorph`) exercises the binding/configuration directly via a logback `ListAppender` attached to the class logger. diff --git a/docs/RELEASE.md b/docs/RELEASE.md index 8f739a7..9990ea1 100644 --- a/docs/RELEASE.md +++ b/docs/RELEASE.md @@ -3,5 +3,33 @@ The maintainer-facing release procedure is **centralized in the workspace repo**: [`../workspace/workflows/release-process.md`](../workspace/workflows/release-process.md). -llamacpp-ai-index-maven-plugin is a single-module Maven project (one `pom.xml`, one `README.md` -dependency snippet), so the canonical procedure applies as-is — there is no repo-specific supplement. +**This repo-specific supplement applies here** — srcmorph is a 3-module Maven reactor +(`srcmorph`, `srcmorph-cli`, `srcmorph-maven-plugin`, all released together from one parent pom +at the same version), not a single-module project, so a few steps differ from the generic +procedure: + +1. **Bump to the release version** before tagging: + ```bash + mvn versions:set -DnewVersion=X.Y.Z -DgenerateBackupPoms=false + ``` + (No `-Dexcludes` needed — the reactor's former 4th module, a relocation-stub POM for the + retired `net.ladenthin:llamacpp-ai-index-maven-plugin` coordinates, was removed after its one + `1.0.4` release; see `CLAUDE.md`.) +2. **Commit, push, merge to `main`.** +3. **Tag the merge commit and push the tag:** + ```bash + git tag vX.Y.Z + git push origin vX.Y.Z + ``` +4. **Manually trigger the release**: GitHub → Actions → *Publish* → **Run workflow**, select the + `vX.Y.Z` tag, and check `publish_to_central`. `publish-release` only runs when **both** the ref + is a `v*` tag **and** the workflow was dispatched with that flag — a plain tag push or a push to + `main` alone does not publish anything. +5. **Verify** the release actually reached Central before considering it done: check + `https://repo1.maven.org/maven2/net/ladenthin//X.Y.Z/` for each of the three + artifacts, and confirm the CI run's "Deploy release" step succeeded (not just "completed"). +6. **Bump `main` forward** to the next `-SNAPSHOT` version (same `versions:set` command) so `main` + never again sits at a version matching a published release. + +See `CHANGELOG.md` for the format of the release notes entry that should exist for `X.Y.Z` before +tagging. diff --git a/llamacpp-ai-index-maven-plugin/pom.xml b/llamacpp-ai-index-maven-plugin/pom.xml deleted file mode 100644 index 40c3d45..0000000 --- a/llamacpp-ai-index-maven-plugin/pom.xml +++ /dev/null @@ -1,72 +0,0 @@ - - - - - 4.0.0 - - - net.ladenthin - srcmorph-parent - 1.2.0-SNAPSHOT - ../pom.xml - - - llamacpp-ai-index-maven-plugin - - 1.0.4 - pom - - llamacpp-ai-index-maven-plugin (relocated) - Relocated. This artifact moved to net.ladenthin:srcmorph-maven-plugin; see the distributionManagement/relocation below. - - - - net.ladenthin - srcmorph-maven-plugin - 1.1.1 - - - diff --git a/pom.xml b/pom.xml index 1007b4f..4db37f4 100644 --- a/pom.xml +++ b/pom.xml @@ -67,24 +67,23 @@ SPDX-License-Identifier: Apache-2.0 provider/support — framework-free, no Maven plugin API); `srcmorph-cli` is the standalone JSON/YAML-driven CLI (fat jar deliverable) built on top of it; `srcmorph-maven-plugin` depends on the core library too and supplies only the Mojo entry points (renamed from - `llamacpp-ai-index-maven-plugin` in the final migration step — goal prefix `srcmorph`, - package `net.ladenthin.maven.srcmorph.mojo`, properties `srcmorph.*`). + `llamacpp-ai-index-maven-plugin` in the migration — goal prefix `srcmorph`, package + `net.ladenthin.maven.srcmorph.mojo`, properties `srcmorph.*`). - `llamacpp-ai-index-maven-plugin` here is NOT the renamed plugin — it is a separate, - minimal relocation-stub module (its own pom.xml has no , is version-pinned - independently at 1.0.4, and carries only a pointing - at srcmorph-maven-plugin) kept only so Maven Central consumers still resolving the old - coordinates get redirected. IMPORTANT: `mvn versions:set` run from this root walks every - module in this list, including that stub — always pass - `-Dexcludes=net.ladenthin:llamacpp-ai-index-maven-plugin` when bumping the reactor version - so its pinned 1.0.4 is never accidentally overwritten. See that module's own pom.xml - comment and TODO.md for the same caveat. + A fourth module, a minimal relocation-stub POM for the retired + `net.ladenthin:llamacpp-ai-index-maven-plugin` coordinates (no , version-pinned at + 1.0.4, only a pointing at srcmorph-maven-plugin:1.1.1), + was published to Maven Central and then removed from this reactor — the published artifact + is permanent on Central regardless of what this repo's module list contains, and the + relocation was verified working end-to-end (a clean-repo Maven resolution of the old + coordinates correctly redirects to the new ones) before removal. There is nothing left for + that module to do: it will never be re-released, so keeping it in the active reactor (and + the `versions:set -Dexcludes=...` footgun that came with it) served no further purpose. --> srcmorph srcmorph-cli srcmorph-maven-plugin - llamacpp-ai-index-maven-plugin diff --git a/srcmorph-maven-plugin/README.md b/srcmorph-maven-plugin/README.md index a3bf093..875dcc9 100644 --- a/srcmorph-maven-plugin/README.md +++ b/srcmorph-maven-plugin/README.md @@ -9,10 +9,10 @@ retrieval. > for the product overview, badges, and build status. **This plugin was renamed** from > `net.ladenthin:llamacpp-ai-index-maven-plugin` to `net.ladenthin:srcmorph-maven-plugin` (goal > prefix `srcmorph`, properties `srcmorph.*`) as part of the reactor migration's final step. -> Consumers still declaring the old coordinates are transparently redirected: the old artifactId is -> now published only as a tiny relocation-stub POM -> (`../llamacpp-ai-index-maven-plugin/pom.xml`, ``) pointing here -> — see the root README's migration note. Internally, the plugin depends on +> Consumers still declaring the old coordinates are transparently redirected: the old artifactId was +> published once (`1.0.4`, a tiny relocation-stub POM with only a +> `` pointing here) and the redirect verified working — see the +> root README's migration note. Internally, the plugin depends on > [`net.ladenthin:srcmorph`](../srcmorph/README.md) (a sibling reactor module) for all of > its engine/indexing logic — the 5 Mojo classes in this module are thin wrappers that map their > `@Parameter` fields onto a shared `SrcMorphConfiguration` and delegate to one of `srcmorph`'s diff --git a/srcmorph/spotbugs-exclude.xml b/srcmorph/spotbugs-exclude.xml index 4d92b35..740cf45 100644 --- a/srcmorph/spotbugs-exclude.xml +++ b/srcmorph/spotbugs-exclude.xml @@ -15,7 +15,7 @@ SPDX-License-Identifier: Apache-2.0 AiFieldGenerationConfig and AiPromptDefinition are mutable JavaBean POJOs that the Maven plugin framework instantiates via reflection, populates through setters, and stores in a List<...> @Parameter field - on the parent Mojo (in the llamacpp-ai-index-maven-plugin module). No + on the parent Mojo (in the srcmorph-maven-plugin module). No code path compares two instances for value equality; the surrounding Mojo iterates the list in source order and uses the (non-null) string keys (promptKey, aiDefinitionKey, AiPromptDefinition.key) to drive @@ -100,7 +100,7 @@ SPDX-License-Identifier: Apache-2.0 emit. The collateral cost is small: any handwritten member of those four names that genuinely stores-then-immediately-returns is either a debugger-friendly local-variable pattern or a micro-optimisation, both intentional here. (Duplicated - verbatim in the llamacpp-ai-index-maven-plugin module's spotbugs-exclude.xml since + verbatim in the srcmorph-maven-plugin module's spotbugs-exclude.xml since this rule is not class-scoped and both modules have Lombok-annotated classes.) --> @@ -145,7 +145,7 @@ SPDX-License-Identifier: Apache-2.0 when it sees no matching-visibility call site within the analyzed class set. Before the extraction both call sites (AggregateProjectMojo constructing ProjectIndexer; GenerateMojo calling SourceFileIndexer.classify) lived in the same single module and satisfied the - detector; now those callers live in the sibling llamacpp-ai-index-maven-plugin module, + detector; now those callers live in the sibling srcmorph-maven-plugin module, outside this module's own SpotBugs analysis unit, so the detector can no longer see them. Both members are genuinely public API by design (the constructor is srcmorph's cross-module entry point for project-level indexing; classify() is exercised directly by @@ -166,7 +166,7 @@ SPDX-License-Identifier: Apache-2.0 @@ -357,7 +357,7 @@ SPDX-License-Identifier: Apache-2.0 - WEM_WEAK_EXCEPTION_MESSAGING: AiConditionEvaluator.validate's message describes a POM configuration error in operator terms; it intentionally reads as a user-facing config diagnostic rather than carrying internal state (the matching GenerateMojo/CalibrateMojo - WEM suppression lives in the llamacpp-ai-index-maven-plugin module's own filter file). + WEM suppression lives in the srcmorph-maven-plugin module's own filter file). - RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE: arises from the Objects.requireNonNull / @NullMarked validation style (see the DCN rationale in the plugin module's filter file); the explicit guards are the deliberate fail-fast contract, not dead checks. @@ -463,7 +463,7 @@ SPDX-License-Identifier: Apache-2.0 DCN_NULLPOINTER_EXCEPTION on EngineSupport.buildPromptSupport / buildAiModelDefinitionSupport and GenerateEngine.resolveSharedFacts. Moved verbatim (same rationale) from what was AbstractAiIndexMojo.buildPromptSupport / buildAiModelDefinitionSupport and - GenerateMojo.resolveSharedFacts in the llamacpp-ai-index-maven-plugin module's own filter file + GenerateMojo.resolveSharedFacts in the srcmorph-maven-plugin module's own filter file (see that file for the full "why not the alternatives" reasoning): these catch sites are the deliberate translation bridge between the support classes' Objects.requireNonNull validation (which throws NPE by Java convention with the rich index + bad-entry message) and the engine @@ -480,7 +480,7 @@ SPDX-License-Identifier: Apache-2.0