Skip to content

Commit

Permalink
release: generate build artifacts prior to release
Browse files Browse the repository at this point in the history
this makes sure they are in the release git commit, which is prepared
before the prepublishOnly task generates these things otherwise
  • Loading branch information
mikehardy committed Dec 20, 2024
1 parent f00a8e2 commit d41fbfb
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,23 @@ jobs:
distribution: 'temurin'
java-version: '17'


# semantic-release uses npm to do final prepare + package + publish
# npm will not tolerate node_modules directories installed via yarn
# so yarn must not be used in this workflow
# there will be errors related to pod-install but we can ignore them
- name: Install dependencies using NPM
run: npm i

# The release script runs packages/react-native/package.json::prepublishOnly
# which will generate these artifacts, but it does that *after* it commits
# to git, so we don't get the Android AAR or the reference API typedoc unless
# we generate them prior to running the release
- name: Generate artifacts before release
run: |
npm run build:core
npm run gen:reference
- name: Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: npx semantic-release
run: npx semantic-release

0 comments on commit d41fbfb

Please sign in to comment.