relimpact
Release Impact Analyzer for Go projects — catch breaking API changes, docs updates & important file diffs — fast.
In modern Go projects, it's too easy for accidental API changes or subtle documentation edits to sneak through pull requests or release processes unnoticed.
relimpact
is a lightweight CLI tool that helps you understand what really changed between two Git refs — with clean, structured, human-friendly reports.
Use it in CI pipelines, release PRs, or locally before tagging new versions.
✨ Features
- 🔍 API Diff — Track breaking public API changes (structs, interfaces, functions, constants, variables).
- 📝 Docs Diff — Section-aware Markdown diff to highlight meaningful content changes.
- 🗂️ Other Files Diff — Group file changes by extension (.sh, .sql, .json, etc.) to surface migrations and auxiliary files.
- 🚀 Designed for Release PR reviews — Quickly see the real impact of changes.
- 🖋️ Markdown Reports — Ready to paste into GitHub Releases, Slack, or changelogs.
- ⚙️ Works in GitHub Actions, GitLab CI, or locally — Integrates easily.
- 🔒 No server required — Pure CLI tool.
🚀 Quickstart
Run on a GitHub PR:
relimpact --old=v1.0.0 --new=HEAD > release-impact.md
Example Output:
Expanded Sections
PR Comment Generated
⚙️ GitHub Action Integration
name: Release Impact on PR on: pull_request: branches: [ master ] types: [ opened, synchronize, reopened ] jobs: release-impact: name: Generate Release Impact Report runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - name: Determine previous tag id: prevtag run: | git fetch --tags TAG_LIST=$(git tag --sort=-version:refname) PREV_TAG=$(echo "$TAG_LIST" | head -n2 | tail -n1) echo "Previous tag: $PREV_TAG" # Fallback to first tag if no previous if [ -z "$PREV_TAG" ]; then PREV_TAG=$(echo "$TAG_LIST" | head -n1) echo "Fallback to first tag: $PREV_TAG" fi echo "prev_tag=$PREV_TAG" >> $GITHUB_OUTPUT - name: Determine new ref id: newref run: | if [ "${{ github.event_name }}" = "pull_request" ]; then echo "new_ref=${{ github.event.pull_request.head.sha }}" >> $GITHUB_OUTPUT else echo "new_ref=HEAD" >> $GITHUB_OUTPUT fi # Cache restore for old ref - name: Cache API snapshot (old ref) uses: actions/cache/restore@v4 id: cache-old with: path: .cache/relimpact-api-cache key: relimpact-api-${{ steps.prevtag.outputs.prev_tag }} restore-keys: | relimpact-api- # Cache restore for new ref - name: Cache API snapshot (new ref) uses: actions/cache/restore@v4 id: cache-new with: path: .cache/relimpact-api-cache key: relimpact-api-${{ steps.newref.outputs.new_ref }} restore-keys: | relimpact-api- # Run your relimpact-action (this runs SnapshotAPI and writes cache) - uses: hashmap-kz/relimpact-action@main with: old-ref: ${{ steps.prevtag.outputs.prev_tag }} new-ref: ${{ steps.newref.outputs.new_ref }} output: release-impact.md env: RELIMPACT_API_CACHE_DIR: ${{ github.workspace }}/.cache/relimpact-api-cache # Cache save for old ref — only if not already restored - name: Save API snapshot cache (old ref) if: steps.cache-old.outputs.cache-hit != 'true' uses: actions/cache/save@v4 with: path: .cache/relimpact-api-cache key: relimpact-api-${{ steps.prevtag.outputs.prev_tag }} # Cache save for new ref — only if not already restored - name: Save API snapshot cache (new ref) if: steps.cache-new.outputs.cache-hit != 'true' uses: actions/cache/save@v4 with: path: .cache/relimpact-api-cache key: relimpact-api-${{ steps.newref.outputs.new_ref }} # Upload the release impact report - name: Upload Release Impact Report uses: actions/upload-artifact@v4 with: name: release-impact-${{ github.run_id }}-${{ github.run_attempt }} path: release-impact.md # Post release impact to PR comment - name: Post Release Impact to PR if: github.event_name == 'pull_request' uses: marocchino/sticky-pull-request-comment@v2 with: recreate: true path: release-impact.md
📦 Installation
Homebrew
brew tap hashmap-kz/homebrew-tap brew install relimpact
Manual Download
🧠 How It Works
1️⃣ Go Source API Changes
- Uses Go type system & AST parsing:
- Detects breaking changes: method signatures, removed fields, new/removed types, etc.
- Ignores formatting & comment noise.
- Based on
golang.org/x/tools/go/packages
.
2️⃣ Markdown Docs Changes
- Section-aware diff of
.md
files:- Headings added/removed.
- Links and images changes.
- Section word count diffs.
- Based on
goldmark
parser.
3️⃣ Other Files Changes
- Groups changes by file type:
-
.sql
,.sh
,.json
,.yaml
,.conf
, etc. - Uses
git diff --name-status
.
-
Why Use It?
Most release PRs include:
✅ API changes
✅ Doc updates
✅ Migration scripts
✅ Other important config tweaks
But raw git diff
is noisy and hard to review.
relimpact
gives you a release-ready summary, focusing on what's important.
📜 License
MIT License. See LICENSE.
👉 Try it today: https://github.com/hashmap-kz/relimpact
If you found this useful, leave a ⭐ on GitHub — it helps others discover the project!
Happy releasing 🚀
Top comments (0)