Ghr, a GitHub Releases installer built with Zig and for Zig apps too

ghr - a GitHub Releases installer


This was my first real Zig project. I’ve been iterating on it for 3 months, so I learned a lot about Zig and its community. The project aims to help the community make their software installable. It also makes it easier to make forks installable as well as mirroring. I personally use it a lot when setting up new machines or containers.

I adopted the minisign signatures for verifying the binary author. Here is my GitHub Actions setup that installs the mirrored Zig binary.

      - name: Install Zig via ghr
        uses: cataggar/ghr/actions/install@v0.6.1
        env:
          GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          tools: |
            cataggar/zig@v0.16.0 RWSGOq2NVecA2UPNdBUZykf1CCb147pkmdtYxgb3Ti+JO/wCYvhbAb/U

I’ve started a blog with some posts about ghr:

  • ghr — a toolkit for GitHub Releases
  • Installable WebAssembly Apps
  • installable WASI 0.3 Pet Store example

The project itself is: GitHub - cataggar/ghr: A toolkit for GitHub releases. · GitHub

I recently added support for WebAssembly apps. Those example WebAssembly apps are made with Zig and installable with ghr. I love seeing the WebAssembly enhancements land in Zig. The current blocker for using the native (non-LLVM) backend is:

  • #35795 - wasm trap with native backend - ziglang/zig

Would appreciate some help getting that resolved in Codeberg.

Supported Zig versions

The project will follow Zig stable, currently 0.16.

AI / LLM usage disclosure

I use Copilot when coding. This project is reviewed, tested, and engineered iteratively.

2 Likes

I just released ghr v0.9.0. The documentation at ghr — a toolkit for GitHub releases — ghr is much improved. It is my first release using zig v0.17.0.

When I create a new development machine, here is an example of what I run to set up my development environment:

curl -fsSL https://raw.githubusercontent.com/cataggar/ghr/main/install.sh | sh
ghr install cli/cli github/copilot-cli cataggar/keyring cataggar/zig burntsushi/ripgrep clementtsang/bottom nushell/nushell astral-sh/uv casey/just bytecodealliance/wasmtime

I relaxed the minisign requirement in this version. I have a mirror of the stable zig releases at GitHub - cataggar/zig · GitHub, so these all install the same official zig v0.17.0. The last is the new syntax to support other options.

ghr install cataggar/zig
ghr install cataggar/zig@v0.17.0 RWSGOq2NVecA2UPNdBUZykf1CCb147pkmdtYxgb3Ti+JO/wCYvhbAb/U
ghr install cataggar/zig@v0.17.0 ?minisign=RWSGOq2NVecA2UPNdBUZykf1CCb147pkmdtYxgb3Ti+JO/wCYvhbAb/U

For those using AI, the Zig incremental build support is impressive. I added this skill today: