Skip to main content

Interact with WebAssembly registries.

Project description

wasm-action

Interact with WebAssembly registries.

Features

  • Versatile use as a GitHub action, CLI or Python library.
  • Supported registry types: warg (wa.dev)
  • Supported artifact types: wasm
  • Supported actions: pull (public and private packages)
  • Supports Python 3.10+ on Linux, MacOS and Windows

Usage

Pull from registry

      - uses: xelato/wasm-action
        with:
          action: pull
          registry: wa.dev
          package: component-book:adder

To pull a private package define your token:

        env:
          WARG_TOKEN: ${{ secrets.WARG_TOKEN }}

Inputs

Name Description Required Example
action Pull from registry yes pull
registry Registry domain name yes wa.dev
package Package specification yes namespace:name@version
namespace:name
namespace/name
namespace/name@version
path Target path to save the download no file.wasm

Outputs:

Name Description Example
registry Registry domain name wa.dev
registry-type Detected registry type warg
package Package foo:bar@1.2.3
package-namespace Package namespace foo
package-name Package name bar
package-version Package version 1.2.3
filename Download location foo-bar_1.2.3.wasm
digest File hash sha256:2afffac0...

CLI

The tool can be run without installing using uv.

$ uvx wasm-action --help
Usage: wasm-action [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  pull  Pull from a WebAssembly registry
  push  Push to a WebAssembly registry
$ uvx wasm-action pull --help
Usage: wasm-action pull [OPTIONS]

  Pull from a WebAssembly registry

Options:
  --registry TEXT    registry domain name  [required]
  --package TEXT     package spec  [required]
  --path TEXT        filename
  --warg-token TEXT  warg token
  --help             Show this message and exit.
$ uvx wasm-action pull --registry wa.dev --package wasi:io
registry=wa.dev
registry-type=warg
warg-url=https://warg.wa.dev
package=wasi:io@0.2.0
package-namespace=wasi
package-name=io
package-version=0.2.0
digest=sha256:c33b1dbf050f64229ff4decbf9a3d3420e0643a86f5f0cea29f81054820020a6
filename=wasi:io@0.2.0.wasm
$ file wasi:io@0.2.0.wasm 
wasi:io@0.2.0.wasm: WebAssembly (wasm) binary module version 0x1000d

Use as Library

The package is published to the Python Package Index and can be installed/depended-on under the name wasm-action on all supported Python versions.

$ pip install wasm-action
> import wasm_action as wa

However, the library interface is not yet standardised and may (and will!) change.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wasm_action-0.0.2.tar.gz (39.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wasm_action-0.0.2-py3-none-any.whl (101.6 kB view details)

Uploaded Python 3

File details

Details for the file wasm_action-0.0.2.tar.gz.

File metadata

  • Download URL: wasm_action-0.0.2.tar.gz
  • Upload date:
  • Size: 39.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for wasm_action-0.0.2.tar.gz
Algorithm Hash digest
SHA256 ee2ec32ffe346b778aaa383cf9980cf89fda52d42ad411ad7ff77d61f9d8b0da
MD5 5226d2ae93782bfb599d7624ce6d3b52
BLAKE2b-256 f7346226d38a8863c388469fc4219ce4f100c44b77cbeed5c98c10006422048e

See more details on using hashes here.

Provenance

The following attestation bundles were made for wasm_action-0.0.2.tar.gz:

Publisher: release.yml on xelato/wasm-action

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file wasm_action-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: wasm_action-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 101.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for wasm_action-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 e52523a6c067192c0b730051afc6abdb16de204d7f22bf1cc8bd80749da20192
MD5 da0e9dceb2256dc2cdbae4abbf7459e2
BLAKE2b-256 787a0ae443c3815b27c5e39052debd697532926d26a5c6f29fc73634d1f29ae7

See more details on using hashes here.

Provenance

The following attestation bundles were made for wasm_action-0.0.2-py3-none-any.whl:

Publisher: release.yml on xelato/wasm-action

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page