Skip to content

feat: publish Arch Linux package to the AUR (#29) - #36

Open
rapatao wants to merge 1 commit into
mainfrom
feat/aur-package
Open

feat: publish Arch Linux package to the AUR (#29)#36
rapatao wants to merge 1 commit into
mainfrom
feat/aur-package

Conversation

@rapatao

@rapatao rapatao commented Jul 4, 2026

Copy link
Copy Markdown
Owner

Closes #29.

What

Publishes an AUR package (md2-bin) so Arch/Manjaro users can yay -S md2-bin / paru -S md2-bin, rounding out Linux distro coverage alongside the .deb/.rpm/.apk packages (#28).

Adds a goreleaser aurs: publisher that generates a PKGBUILD + .SRCINFO from the already-built linux tar.gz archives (no build-from-source; md2 is CGO-free) and pushes them to aur.archlinux.org over SSH — mirroring the existing homebrew_casks:/nix: publishers.

  • .goreleaser.yamlaurs: block (name md2-bin, provides/conflicts md2, optdepends chromium, skip_upload: auto, custom package() installing the binary + MIT LICENSE text)
  • .github/workflows/release.yml — forwards the AUR_KEY secret to goreleaser
  • README.md — Arch Linux (AUR) install entry

AUR-guidelines compliance

  • md2-bin — the -bin suffix is required for prebuilt-binary packages whose sources are public.
  • goreleaser auto-generates .SRCINFO and the maintainer comment; references the release tarball via source= + sha256 (tarball/filelist never committed); pushes to the master branch.
  • MIT is a "custom" license on Arch, so package() installs the LICENSE text to /usr/share/licenses/md2-bin/ (keeps namcap clean).

Verified

goreleaser check passes; a snapshot build (release --snapshot --skip=publish,...) generated a correct PKGBUILD + .SRCINFO with arch-specific source_x86_64/source_aarch64 arrays and the binary + license install.

⚠️ Manual steps required before merging

The aurs: publisher is inert until these one-time, out-of-repo steps are done by the maintainer:

  1. Arch Linux / AUR account — sign in at https://aur.archlinux.org and register an SSH public key under My Account → SSH Public Key. The key pair must be passwordless (goreleaser cannot use a password-protected key).
  2. Add the AUR_KEY repository secret — GitHub → Settings → Secrets and variables → Actions → new secret AUR_KEY = the matching private (passwordless) SSH key.
  3. md2-bin package name — goreleaser auto-creates the AUR repo on the first non-prerelease tag push (ssh://aur@aur.archlinux.org/md2-bin.git) if the name is free and the key is authorized. No manual registration needed beyond having the account + key.

Notes:

  • skip_upload: autoprereleases do not push to AUR; tag an -rc first to sanity-check without touching AUR.
  • After the first real release, verify with yay -S md2-bin / paru -S md2-bin.

Add a goreleaser `aurs:` publisher that generates a PKGBUILD + .SRCINFO
from the already-built linux tar.gz archives and pushes them to
aur.archlinux.org, mirroring the existing homebrew_casks/nix publishers.

The AUR package is named md2-bin: the -bin suffix is required by AUR
guidelines for prebuilt-binary packages whose sources are public. The
generated package() installs the binary and, since MIT is a custom
license on Arch, the LICENSE text. Pushes are skipped on prereleases
(skip_upload: auto). The release workflow forwards the AUR_KEY secret
(passwordless SSH private key) to goreleaser.

README gains an Arch Linux (AUR) install entry.
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.

Publish Arch Linux package (AUR)

1 participant