Supporting go install #49
Labels
No labels
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/OpenSpec
Kind/Security
Kind/Testing
Priority/Critical
Priority/High
Priority/Low
Priority/Medium
RFC - Request For Comments
Reviewed/Confirmed
Reviewed/Duplicate
Reviewed/Invalid
Reviewed/Won't Fix
Status/Abandoned
Status/Blocked
Status/Need More Info
hermes-attempted
hermes-needs-clarification
hermes-ready
hermes-review
hermes-wip
human-required
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
agentic-forges/forgejo-mcp#49
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hello, thank you for this! It's really nice to be able to organise issues with GitHub with the their MCP server, so getting similar for Codeberg is very nice.
When setting up new projects, we typically use a Makefile or more often, Taskfile. In that file, we try to create a setup task that has idempotent commands to install the required commands. I love to use
go installfor that, because we can list all the command line utilities along with their version.All this is to say, it would be nice to be able to install this MCP server with
go install(or be able to download a release binary).@simenandre hey, thanks for raising this. Do you want to/can you add the go bits needed for this, or shall I have a look at it?
User Story
As a developer setting up new projects with Makefiles or Taskfiles,
I want to install forgejo-mcp using
go installor download pre-built release binaries,So that I can use idempotent commands to install required CLI utilities with explicit version control.
Acceptance Criteria
go install codeberg.org/goern/forgejo-mcp@latestworks correctlygo install codeberg.org/goern/forgejo-mcp@v0.x.xinstalls specific versionsforgejo-mcp --version)Implementation Plan
1. Ensure Go Module Compatibility
go.modmodule path iscodeberg.org/goern/forgejo-mcpmain.gois in the repository root (or use appropriate package path)go installfrom source works locally2. Add Version Information
-ldflagsat build time--versionflag to the CLI if not present3. Set Up CI/CD for Releases
linux/amd64,linux/arm64darwin/amd64,darwin/arm64windows/amd644. Documentation
go installinstructionsThis approach gives users two options:
go installfor those with Go installed, and direct binary downloads for others.Implementation Plan
Root Cause
The current module path
forgejo.org/forgejo/forgejo-mcpingo.moddoesn't resolve via Go's module proxy. Forgo install codeberg.org/goern/forgejo-mcp@latestto work, the module path must match the repository URL.Solution
Change module path from
forgejo.org/forgejo/forgejo-mcptocodeberg.org/goern/forgejo-mcp.Implementation Steps
go.mod- Change module declarationgo mod tidy- Ensure dependencies resolveREADME.md- Addgo installas primary installation methodFiles to Modify
go.modmain.gocmd/cmd.gooperation/operation.gooperation/issue/issue.gooperation/pull/pull.gooperation/repo/repo.gooperation/repo/branch.gooperation/repo/commit.gooperation/repo/file.gooperation/search/search.gooperation/user/user.gooperation/version/version.gooperation/wiki/wiki.gopkg/forgejo/forgejo.gopkg/log/log.gopkg/to/to.goREADME.mdREADME Addition
Already Complete
--versionflag supportRisk Assessment
This is a breaking change for anyone importing this module as a library. However, since this is an end-user CLI tool (not a library), impact should be minimal.