Update host package README for app developers (#400) #166
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| env: | |
| # Version here should match the one in React Native template and packages/cmake-rn/src/cli.ts | |
| NDK_VERSION: 27.1.12297006 | |
| # pnpm records GitHub git dependencies (e.g. node-addon-examples) with an SSH | |
| # repo URL, which anonymous CI runners can't clone. Rewrite git@github.com: to | |
| # HTTPS so the public repo is fetched over HTTPS. | |
| GIT_CONFIG_COUNT: 1 | |
| GIT_CONFIG_KEY_0: "url.https://github.com/.insteadOf" | |
| GIT_CONFIG_VALUE_0: "git@github.com:" | |
| on: | |
| push: | |
| branches: | |
| - main | |
| concurrency: ${{ github.workflow }}-${{ github.ref }} | |
| jobs: | |
| release: | |
| name: Release | |
| runs-on: macos-latest | |
| environment: main | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v4 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: lts/krypton | |
| cache: pnpm | |
| - name: Setup cpp tools | |
| uses: aminya/setup-cpp@v1 | |
| with: | |
| clang-format: true | |
| - name: ccache | |
| uses: hendrikmuhs/ccache-action@v1.2 | |
| with: | |
| key: ${{ github.job }}-${{ runner.os }} | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v3 | |
| with: | |
| java-version: "17" | |
| distribution: "temurin" | |
| - name: Setup Android SDK | |
| uses: android-actions/setup-android@v3 | |
| with: | |
| packages: tools platform-tools ndk;${{ env.NDK_VERSION }} | |
| - run: rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi i686-linux-android aarch64-apple-ios-sim | |
| - run: pnpm install | |
| - name: Create Release Pull Request or Publish to NPM | |
| id: changesets | |
| uses: changesets/action@v1 | |
| with: | |
| publish: pnpm run release | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| # Changesets shells out to `npm info` (there is no pnpm equivalent it | |
| # can use) to determine what is already published. npm ≥ 11 checks the | |
| # root package.json's "devEngines" on every command and errors with | |
| # EBADDEVENGINES because we require pnpm as the package manager, which | |
| # fails the publish before it starts. Passing force downgrades that | |
| # check to a warning; the actual publishing still runs through | |
| # `pnpm publish`. Changesets v3 fixes this properly by running | |
| # `pnpm info` when pnpm is detected, but it needs changesets/action v2 | |
| # to go with it and both are prereleases for now — remove this once we | |
| # upgrade to those. | |
| npm_config_force: true |