Skip to content

Add release automation and installation methods#20

Merged
jfox85 merged 4 commits intomainfrom
jf-release-process
Oct 1, 2025
Merged

Add release automation and installation methods#20
jfox85 merged 4 commits intomainfrom
jf-release-process

Conversation

@jfox85
Copy link
Owner

@jfox85 jfox85 commented Oct 1, 2025

Summary

  • Add GoReleaser configuration for automated releases
  • Add GitHub Actions workflow for tag-based releases
  • Add universal install script with platform detection
  • Add comprehensive installation documentation to README
  • Set up Homebrew tap support via jfox85/homebrew-devx

Installation Methods Added

  1. Homebrew: brew tap jfox85/homebrew-devx && brew install devx
  2. Universal script: curl -fsSL https://raw.githubusercontent.com/jfox85/devx/main/install/install.sh | bash
  3. go install: go install github.com/jfox85/devx@latest
  4. Direct download: From GitHub releases page
  5. Build from source: make build (existing)

Technical Details

  • GoReleaser v2 configuration with proper ldflags for version injection
  • Builds for darwin/linux on amd64/arm64 architectures
  • Automatic Homebrew formula generation and publishing
  • Install script with error handling, platform detection, and cleanup
  • Cross-repo GitHub token support for Homebrew tap updates

Testing Completed

✅ Build from source with version injection
✅ GoReleaser snapshot builds
✅ Install script validation
✅ All tests passing with race detection
✅ Code formatting and linting clean

Next Steps After Merge

  1. Add HOMEBREW_TAP_TOKEN GitHub secret (fine-grained PAT)
  2. Tag first release: git tag v0.1.0 && git push origin v0.1.0
  3. Verify GitHub Actions workflow completes successfully
  4. Test all installation methods with real release

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Added one-line installer and a web redirect page for easy setup.
    • Provided prebuilt binaries for macOS and Linux (amd64/arm64).
    • Introduced Homebrew tap support for simple installs and updates.
  • Documentation
    • Expanded installation methods, usage examples, and environment variable guidance.
    • Clarified alternative build targets and workflows.
  • Chores
    • Implemented automated release pipeline with versioned builds, archives, and changelog generation.
    • Added MIT license to the project.

jfox85 and others added 4 commits October 1, 2025 12:22
- Update .goreleaser.yaml to v2 format (version: 2)
- Change deprecated 'tap' to 'repository' field
- Remove deprecated fields: snapshot.name_template, archives.format, checksums, strip_parent_binary_folder
- Add HOMEBREW_TAP_GITHUB_TOKEN support for cross-repo Homebrew tap updates
- Remove unnecessary Go dependency from Homebrew formula
- Add MIT license content to LICENSE file

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@coderabbitai
Copy link

coderabbitai bot commented Oct 1, 2025

Walkthrough

Adds a release pipeline via GitHub Actions and GoReleaser, introduces a full GoReleaser config with Homebrew tap publishing, includes a Bash installer and an HTML redirect page, and updates documentation with installation methods and license.

Changes

Cohort / File(s) Summary
CI: Release Workflow
.github/workflows/release.yml
New workflow triggered by tags matching v*. Checks out repo (fetch-depth 0), sets up Go (from go.mod), caches modules, installs GoReleaser v6, and runs release. Uses GITHUB_TOKEN and HOMEBREW_TAP_TOKEN env vars.
Release Packaging
.goreleaser.yaml
Adds GoReleaser v2 config: builds devx for darwin/linux (amd64, arm64), embeds version metadata, archives with LICENSE/README, git-based changelog, Homebrew tap publish (token via HOMEBREW_TAP_GITHUB_TOKEN), announce skipped.
Installer Assets
install/install.sh, install/install-redirect.html
Bash installer downloads correct OS/arch tarball from GitHub Releases, installs to DEVX_INSTALL_DIR (default /usr/local/bin), cleans up, basic validation/help. HTML page meta-redirects to latest install script URL.
Docs & License
README.md, LICENSE
README adds installation methods and usage; updates section labels. LICENSE adds MIT license text. No code changes.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor Dev as Developer
  participant GH as GitHub
  participant GHA as GitHub Actions
  participant GR as GoReleaser
  participant Tap as Homebrew Tap Repo

  Dev->>GH: Push tag vX.Y.Z
  activate GH
  GH-->>GHA: Trigger "Release" workflow
  deactivate GH

  activate GHA
  GHA->>GHA: Checkout, setup Go, cache modules
  GHA->>GR: Run GoReleaser release
  activate GR
  GR->>GH: Create release, upload assets
  GR->>Tap: Push formula updates (token)
  deactivate GR
  GHA-->>Dev: Workflow completes
  deactivate GHA

  note over GR,Tap: Assets: darwin/linux, amd64/arm64 archives with metadata
Loading
sequenceDiagram
  autonumber
  actor U as User
  participant Sh as install.sh
  participant GH as GitHub Releases
  participant OS as System (/usr/local/bin)

  U->>Sh: Run install.sh [optional DEVX_VERSION]
  Sh->>Sh: Detect OS/Arch, prerequisites
  alt DEVX_VERSION=latest
    Sh->>GH: GET latest release tag (API)
    GH-->>Sh: vX.Y.Z
  else specific version
    Sh->>Sh: Normalize with v prefix
  end
  Sh->>GH: Download devx_{{version}}_{{os}}_{{arch}}.tar.gz
  GH-->>Sh: tar.gz
  Sh->>Sh: Extract binary
  Sh->>OS: Install binary (0755)
  Sh->>Sh: Verify devx --version
  Sh-->>U: Done (path to binary)
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

I tagged the sky with v-stars bright,
GoReleaser drums through the night—
Bottles clink in Homebrew’s tap,
A curl, a tar, a tidy wrap.
Hop, install! my paws deploy—
devx is packed—release ahoy! 🐇✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title succinctly and accurately reflects the main changes introduced—adding release automation workflows and various installation methods—without unnecessary detail or noise, making it clear to reviewers what this pull request achieves.
✨ Finishing touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch jf-release-process

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 43e89d3 and 345e94b.

📒 Files selected for processing (6)
  • .github/workflows/release.yml (1 hunks)
  • .goreleaser.yaml (1 hunks)
  • LICENSE (1 hunks)
  • README.md (2 hunks)
  • install/install-redirect.html (1 hunks)
  • install/install.sh (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Build
  • GitHub Check: Build
  • GitHub Check: Test Windows
🔇 Additional comments (1)
install/install.sh (1)

1-82: Installer script looks solid.

Nice job covering dependency checks, OS/arch normalization, version resolution, and cleanup; nothing blocking from my side.


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

@jfox85 jfox85 merged commit 262ff37 into main Oct 1, 2025
23 checks passed
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.

1 participant