# Holepunch GitHub Actions



[`holepunchto/actions`](https://github.com/holepunchto/actions) is a collection of reusable composite GitHub Actions for building, signing, publishing, and recovering Pear applications and Holepunch modules. Reference one with:

```yaml
- uses: holepunchto/actions/<name>@v1
```

<Callout type="info">
  There is no project-scaffolding action. To bootstrap a new Pear project, clone the [`hello-pear-electron`](https://github.com/holepunchto/hello-pear-electron) template. The actions below automate CI/CD once a project exists.
</Callout>

## Pear app CI/CD [#pear-app-cicd]

| Action                                                                                                      | Purpose                                                                                                                                                                                                                                                                                                   | Key inputs / outputs                                                                                                                                                                                                                                                                                                                                                                                                                |
| ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <a name="make-pear-app" />[`make-pear-app`](https://github.com/holepunchto/actions/tree/main/make-pear-app) | Run `npm run make` for the host OS with code signing and notarization, then upload distributables as artifacts. Handles its own `setup-node` + `npm ci`; precede it with `actions/checkout@v4`. See [Build and sign desktop apps in CI](/pear/how-to/operate-an-app/github-actions/build-and-sign-in-ci). | In: `channel` (required), `upgrade_key`, macOS signing/notarization (`macos_certificate_base64`, `macos_p12_password`, `macos_codesign_identity`, `macos_notarization_method` = `appstore_connect` \| `apple_id_password`, plus the matching API-key or Apple-ID fields), Windows signing (`windows_signing_method` = `windows_cert_sha1` \| `windows_cert_pfx`, plus cert fields), `linux_set_up_snapcraft`. Out: `artifact-links` |
| [`pear-ci`](https://github.com/holepunchto/actions/tree/main/pear-ci)                                       | Stage a directory into a [Hyperdrive](/p2p/reference/building-blocks/hyperdrive) on every run, producing a stable `pear://` link. Documented in full at [pear-ci GitHub Action](/pear/reference/ci-and-release/pear-ci-action).                                                                           | `primary-key`, `namespace`, `target`, `dry-run`; out: `pr-url`                                                                                                                                                                                                                                                                                                                                                                      |
| [`pear-provision-recover`](https://github.com/holepunchto/actions/tree/main/pear-provision-recover)         | Recover a provision drive from the network into a new writable drive (runs the `pear-provision-recover` CLI). Used to rebuild write access—see [Recovering from lost write access](/pear/how-to/operate-an-app/manual-deployment/troubleshoot-desktop-releases#recovering-from-lost-write-access).        | `path`, `key`, `length`, `blobs-length`, `primary-key`, `name` (all required)                                                                                                                                                                                                                                                                                                                                                       |

## Release [#release]

| Action                                                                              | Purpose                                                                                                                 | Key inputs                                                                          |
| ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- |
| [`publish`](https://github.com/holepunchto/actions/tree/main/publish)               | `npm publish` (honoring dist-tag and workspaces) then create a GitHub release via `create-release`.                     | `tag` (default `latest`), `workspaces`, `include-workspace-root`, `node-auth-token` |
| [`create-release`](https://github.com/holepunchto/actions/tree/main/create-release) | `npm pack` the packages and attach the tarballs to a `gh release create` for the current ref.                           | `workspaces`, `include-workspace-root`                                              |
| [`trigger-canary`](https://github.com/holepunchto/actions/tree/main/trigger-canary) | Dispatch a `release` event to the `holepunchto/canary-tests` repo so downstream canary tests run against a new release. | `repository`, `ref`, `token` (all required)                                         |

## See also [#see-also]

* [Build and sign desktop apps in CI](/pear/how-to/operate-an-app/github-actions/build-and-sign-in-ci)—the `make-pear-app` walkthrough.
* [Publish with GitHub Actions](/pear/how-to/operate-an-app/github-actions/publish-with-github-actions) and [pear-ci GitHub Action](/pear/reference/ci-and-release/pear-ci-action)—staging with `pear-ci`.
* [Build desktop distributables](/pear/how-to/operate-an-app/build-and-package/build-desktop-distributables)—the manual signing flow `make-pear-app` automates.
* [Native-addon CI prebuilds](/bare/reference/native-addon-prebuilds)—the same `holepunchto/actions` collection's actions for building native Bare addons across platforms.
