An open API service indexing awesome lists of open source software.

https://github.com/vertz-dev/setup-vtz

GitHub Action to install the vtz runtime
https://github.com/vertz-dev/setup-vtz

Last synced: 24 days ago
JSON representation

GitHub Action to install the vtz runtime

Awesome Lists containing this project

README

          

# setup-vtz

GitHub Action to install the [vtz](https://github.com/vertz-dev/vertz) runtime binary.

## Usage

```yaml
steps:
- uses: actions/checkout@v4
- uses: vertz-dev/setup-vtz@v1
- run: vtz --version
```

### Inputs

| Input | Description | Default |
|-------|-------------|---------|
| `version` | vtz version to install. `"auto"` reads from `version.txt` in the repo root. | `auto` |
| `cache` | Enable `actions/cache` for `.pipe/cache` directory. | `true` |

### Outputs

| Output | Description |
|--------|-------------|
| `version` | The vtz version that was installed. |
| `cache-hit` | Whether the cache was restored (`true`/`false`). |

## Examples

### Auto-detect version from `version.txt`

```yaml
- uses: vertz-dev/setup-vtz@v1
- run: vtz --version
```

### Pin to a specific version

```yaml
- uses: vertz-dev/setup-vtz@v1
with:
version: '0.2.57'
```

### Disable cache

```yaml
- uses: vertz-dev/setup-vtz@v1
with:
cache: false
```

### Full CI workflow (Vertz monorepo)

```yaml
jobs:
build-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.9
- run: bun install --frozen-lockfile
- uses: vertz-dev/setup-vtz@v1

# Monorepo-specific: build @vertz/ci for ci.config.ts
- run: cd packages/ci && bun run build

- run: vtz ci build-typecheck --concurrency 2
- run: vtz ci test --concurrency 2
```

## Platform Support

| Runner | Architecture | Status |
|--------|-------------|--------|
| `ubuntu-latest` | x64 | Supported |
| `ubuntu-latest` (ARM) | arm64 | Supported |
| `macos-14` | arm64 | Supported |
| `macos-13` | x64 | Supported |

## How it Works

1. Resolves the version from `version.txt` (or the `version` input)
2. Maps `runner.os`/`runner.arch` to the correct `@vertz/runtime-{os}-{arch}` npm package
3. Downloads and extracts the binary via `npm pack`
4. Adds the binary to `$GITHUB_PATH`
5. Verifies the installed version matches the expected version
6. Optionally restores `.pipe/cache` via `actions/cache`

## License

MIT