Skip to content

[RN][Releases] Automate the draft release creation #1

[RN][Releases] Automate the draft release creation

[RN][Releases] Automate the draft release creation #1

name: Create Draft Release
on:
workflow_call:
pull_request:
jobs:
generate-changelog:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- name: Install dependencies
uses: ./.github/actions/yarn-install
- name: Configure Git
shell: bash
run: |
git config --local user.email "[email protected]"
git config --local user.name "React Native Bot"
- name: Move to the changelog branch
run: git checkout changelog/${{ github.ref }}
- name: Create draft release
uses: actions/github-script@v6
with: |
const {createDraftRelease} = require('./.github/workflow-scripts/createDraftRelease');
const version = v0.79.0-rc.3 //'${{ github.ref_name }}';
const {isLatest} = require('./.github/workflow-scripts/publishTemplate.js');
await generateChangelog(version, isLatest(), '${{secrets.REACT_NATIVE_BOT_GITHUB_TOKEN}}');