Set-Content -Path .\README.md -Value @'
A lightweight GitHub Action that installs voidmerge from the voidmerge GitHub release assets and exposes it on the runner PATH.
This action is intended to make it easy to add voidmerge tooling to workflows by downloading the requested version or the latest available release.
- Installs
voidmergefor the current runner platform - Supports Linux, macOS, and Windows
- Downloads a versioned binary asset from
https://github.com/voidmerge/voidmerge/download - Defaults to the latest
voidmergerelease if no version is provided - Prints the installed
voidmergeversion after installation
| Input | Required | Default | Description |
|---|---|---|---|
voidmerge-version |
No | latest |
The version of voidmerge to download and install. Example: 0.3.5. If omitted or set to latest, the action resolves the most recent GitHub release. |
name: Build documentation
on:
push:
branches:
- main
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up voidmerge
uses: voidmerge/actions-voidmerge@v0.0.1
with:
voidmerge-version: latest
- name: Show voidmerge version
run: voidmerge --version- The action reads the configured version input.
- If the version is omitted or set to
latest, it queries GitHub releases forvoidmerge/voidmerge. - It determines the runner platform and constructs the appropriate release asset URL.
- The action downloads the distribution archive and extracts the
voidmergebinary. - The binary is moved into a tool directory and added to the runner
PATH. - Finally, the action prints the installed
voidmergeversion.
linux→unknown-linux-gnudarwin→apple-darwinwin32→pc-windows-msvc
action.yml— GitHub Action metadata and inputssrc/index.ts— action entry pointsrc/main.ts— main runtime logicsrc/installer.ts— download and install helper functionssrc/get-os.ts— platform to target triple mappingsrc/get-url.ts— asset URL buildersrc/get-latest-version.ts— resolves the latest version from GitHub releaseslib/— compiled output fromnpm run build
npm install
npm run build- The action currently uses
@actions/tool-cache,@actions/io,@actions/exec, andnode-fetch. - If you want to pin a specific
voidmergeversion, provide it through the action input. - The action sets the download destination under the runner's temporary/tool path and adds the binary to
PATH.
This repository does not currently specify a license in package.json.
'@ -Encoding UTF8