8000 mcs: add 0.11.2 by bryan-minimal · Pull Request #922 · gominimal/pkgs · GitHub
[go: up one dir, main page]

Skip to content

mcs: add 0.11.2 - #922

Merged
bryan-minimal merged 3 commits into
mainfrom
add-mcs
Oct 22, 2026
Merged

bryan-minimal merged 3 commits into
mainfrom
add-mcs

Conversation

@bryan-minimal
@bryan-minimal bryan-minimal commented Oct 18, 2026 •
Copy link
Copy Markdown
Member

What

Adds packages/mcs, mcs 0.11.2 (mthmulders/mcs). mcs searches Maven Central from the command line (mcs search <term>, mcs class-search <Class>). Java loadout, #899.

  • Artifact: the pure-JVM mcs-0.11.2.jar from GitHub releases. It is installed at usr/share/mcs/mcs.jar and run on our jdk through a /usr/bin/mcs wrapper (exec java -jar …). sha256 ac99d201…0bf3ad0 matches upstream's checksums_sha256.txt and the release asset digest.
  • Why the jar: upstream's GraalVM native binaries exist only for linux-x86_64. There is no arm64 build. The jar covers both arches with one sha256 and no match target. It is self-contained (picocli, dagger and jackson are shaded in, Main-Class: it.mulders.mcs.App) and needs Java 25 (class file version 69). Our jdk is 25. The README lists no JVM flags for the jar. Its -Djavax.net.ssl.trustStore=… example targets the native binary; with the jar, pass it through JAVA_TOOL_OPTIONS.
  • Runtime deps: jdk, plus bash for the /bin/sh wrapper.
  • Network: every search queries Maven Central (central.sonatype.com), and --show-vulnerabilities also queries Sonatype OSS Index. Following jbang (jbang: add 0.142.0 #903) and curl/go/pnpm/uv, the package declares needs = { dns, internet } for consumers. The build itself is offline.
  • Licence: MIT. Provenance: GithubRepo mthmulders/mcs (tags v<version>).
  • Prebuilt for the same reason as maven / gradle / jdtls: the Maven build resolves dependencies from Maven Central. binary_from records it.

Release age

0.11.2 was published 2026-10-16, about one day before this PR. The pkgs version-age check flags releases younger than 48h, so it may flag this one. If that blocks the PR, the fallback is 0.11.1 (2026-09-17): mcs-0.11.1.jar, sha256 2ea371a06b2c6ca8ff04130670afdf1f0436e49712619e2ab9a1d22327f6f0f2 (also from upstream's checksums_sha256.txt). Only the version and sha256 change.

Tests (Standalone)

  • mcs_version: mcs --version prints exactly mcs v0.11.2.
  • help: mcs --help lists the search and class-search commands, and mcs search --help lists the snippet formats.
  • offline_fails_closed: mcs has no subcommand that works offline, because every search goes to the network. This test pins HTTPS_PROXY/HTTP_PROXY to a closed local port, which mcs honours. mcs search junit:junit must then run the whole query path on our JDK (dagger wiring, HTTP client, error reporting) and fail: non-zero exit, MCS ran into an error, and no Found … results.

Note for reviewers: the standalone test sandbox does have network access for this package. An unpinned mcs search junit returned live results while I was probing. That is why the offline test pins the proxy instead of relying on the sandbox.

Verified

I built it in a pkgbuild session (arm64) with min package build --rebuild --verbose mcs, then ran min check --packages mcs. Every checker passed, including standalone tests, output types valid and missing runtime_deps.

Negative control (fresh session): I expected mcs v0.11.1 and removed the proxy pin. Both mcs_version and offline_fails_closed failed; the second printed live junit:junit search results. I restored the file and re-checked in a fresh session: it passed.

amd64 is left to CI; the jar is architecture-independent.

Refs #899

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Added the Maven Central Search command-line tool, version 0.11.2, for searching Maven Central from the terminal.
    • The tool provides version and help information and reports an error when a search cannot connect to the service.

Search Maven Central from the command line. Ships the pure-JVM jar (native
binaries are linux-x86_64 only) behind a /usr/bin/mcs wrapper on jdk 25.
Consumers inherit needs = { dns, internet }; tests are offline (proxy pinned
to a closed port).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@bryan-minimal
bryan-minimal requested a review from a team as a code owner October 18, 2026 00:50
@coderabbitai
coderabbitai Bot commented Oct 18, 2026 •
Copy link
Copy Markdown
Contributor

Review in Change Stack →

Warning

Review limit reached

  • Run on-demand review

This review includes 2 billable files and costs up to $0.50.

  • Ask an admin to make reviews automatic

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Or wait 15 minutes for your next included review.

Check out review usage here.

View limit details

Limit details: You’ve used all 2 included reviews currently available. Your 58 included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository: gominimal/pkgs/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 503b5f59-1a1c-4752-8b4c-a1d351be2c24
📥 Commits

Reviewing files that changed from the base of the PR and between da00bb6 and 0b5eda3.

📒 Files selected for processing: 2
  • packages/mcs/build.ncl
  • packages/mcs/build.sh

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: gominimal/pkgs/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 11d51060-f696-4e5c-bd26-5c699f9392b0
📥 Commits

Reviewing files that changed from the base of the PR and between c56e4dc and da00bb6.

📒 Files selected for processing: 2
  • packages/mcs/build.ncl
  • packages/mcs/build.sh

Included review availability: This review used your included allowance. 1 included review remains after this review. Your included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour.

📝 Walkthrough

Adds a build specification and packaging script for mcs version 0.11.2. The specification pins the upstream JAR and declares runtime requirements and outputs. Tests check version output, help content, and search failure behavior.

Changes: mcs package

Layer / File(s) Summary
Package definition and installation
packages/mcs/build.ncl, packages/mcs/build.sh
The build specification declares the upstream JAR, package requirements, outputs, and metadata. The packaging script installs the JAR and creates an executable launcher.
CLI behavior tests
packages/mcs/build.ncl
Tests check version output, help content, and error output when a search runs through a closed local proxy.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Feature

Suggested reviewers: 0chroma

Merge Risk: ⚪ Minimal · up to da00b

No confirmed package or CLI issue remains that would prevent merging after normal checks.

Pre-merge checks: Passed 5
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title clearly identifies the package addition and the packaged version, which matches the main change.
Docstring Coverage Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1 files. (1 skipped: 1 unsupported.)

✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

This was referenced Oct 19, 2026
@norrietaylor norrietaylor left a comment
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean. The sha256 matches, needs internet is right for a tool that always queries Maven Central, and the test with the proxy pointed at a closed port exercises the whole query path without reaching the network.

  • Nit, build.ncl:16: "our jdk is 25" will go stale when jdk moves to the next LTS; line 30's "Java 25+" is enough.
  • Nit, line 34: references jbang, which isn't packaged yet (#903 adds it).

Holding approval only on the shared JVM prebuilt-jar policy question, which is being decided once for the batch.


Generated by Claude Code

bryan-minimal added a commit that referenced this pull request Oct 22, 2026
Review nit: cp left the jar mode to however it was fetched; install -m
0644 makes it deterministic, as #922 and #923 do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bryan-minimal added a commit that referenced this pull request Oct 22, 2026
Review nit: cp left the jar mode to however it was fetched; install -m
0644 makes it deterministic, as #922 and #923 do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bryan-minimal and others added 2 commits October 21, 2026 19:06
Review nit: it goes stale when jdk moves to the next LTS; the Java 25+
note on runtime_deps already says what is required.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@bryan-minimal
Copy link
Copy Markdown
Member Author

Thanks @norrietaylor.

bash -n, nickel format --check and mip dump --packages (amd64) are clean after the merge.

🤖 Generated with Claude Code

@norrietaylor norrietaylor left a comment
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving under #970. The "our jdk is 25" comment is gone, the jbang reference is valid now that #903 has merged, and the branch is past #897. Please merge after #970.


Generated by Claude Code

@bryan-minimal
bryan-minimal added this pull request to the merge queue Oct 22, 2026
Merged via the queue into main with commit 85b3ad4 Oct 22, 2026
11 of 12 checks passed
@bryan-minimal
bryan-minimal deleted the add-mcs branch October 22, 2026 23:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0