Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jcbhmr/setup-wasmtime
👩💻 Wasmtime WebAssembly runtime installer for GitHub Actions
https://github.com/jcbhmr/setup-wasmtime
action actions github-action github-actions nodejs setup-action wasmtime webassembly
Last synced: about 2 months ago
JSON representation
👩💻 Wasmtime WebAssembly runtime installer for GitHub Actions
- Host: GitHub
- URL: https://github.com/jcbhmr/setup-wasmtime
- Owner: jcbhmr
- Created: 2024-01-24T02:17:03.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-24T20:07:42.000Z (about 1 year ago)
- Last Synced: 2024-10-27T11:19:24.116Z (3 months ago)
- Topics: action, actions, github-action, github-actions, nodejs, setup-action, wasmtime, webassembly
- Language: JavaScript
- Homepage:
- Size: 815 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Setup Wasmtime
👩💻 [Wasmtime](https://wasmtime.dev/) WebAssembly runtime installer for GitHub Actions
```yml
- uses: jcbhmr/setup-wasmtime@v2
- run: cargo build --target wasm32-wasi
- run: wasmtime target/wasm32-wasi/debug/*.wasm
```🟪 Installs Wasmtime globally \
🔢 Supports semver ranges \
📁 Caches the Wasmtime installation## Usage
![GitHub Actions](https://img.shields.io/static/v1?style=for-the-badge&message=GitHub+Actions&color=2088FF&logo=GitHub+Actions&logoColor=FFFFFF&label=)
![GitHub](https://img.shields.io/static/v1?style=for-the-badge&message=GitHub&color=181717&logo=GitHub&logoColor=FFFFFF&label=)**🚀 Here's what you're after:**
```yml
on: push
jobs:
job:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: jcbhmr/setup-wasmtime@v2
- run: cargo build --target wasm32-wasi
- run: wasmtime target/wasm32-wasi/debug/*.wasm
```### Inputs
- **`wasmtime-version`:** Which version of Wasmtime to install. This can be an exact version specifier such as `16.0.0` or a semver range like `~16.0.0` or `16.x`. Use `latest` to always install the latest release. Defaults to `latest`.
- **`wasmtime-token`:** The GitHub token to use when fetching the version list from [bytecodealliance/wasmtime](https://github.com/bytecodealliance/wasmtime/releases). You shouldn't have to touch this. The default is the `github.token` if you're on github.com or unauthenticated (rate limited) if you're not on github.com.
### Outputs
- **`wasmtime-version`:** The version of Wasmtime that was installed. This will be something like `16.0.0` or similar.
- **`cache-hit`:** Whether or not Wasmtime was restored from the runner's cache or download anew.
## Development
![Node.js](https://img.shields.io/static/v1?style=for-the-badge&message=Node.js&color=339933&logo=Node.js&logoColor=FFFFFF&label=)
**How do I test my changes?** \
Open a Draft Pull Request and some magic GitHub Actions will run to test the action.