| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- name: Release
- on:
- push:
- tags:
- - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
- jobs:
- test:
- uses: ./.github/workflows/test.yml
- release:
- # prevents this action from running on forks
- if: github.repository == 'vuejs/core'
- needs: [test]
- runs-on: ubuntu-latest
- permissions:
- contents: write
- id-token: write
- # Use Release environment for deployment protection
- environment: Release
- steps:
- - name: Checkout
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
- - name: Install pnpm
- uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
- - name: Install Node.js
- uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
- with:
- node-version-file: '.node-version'
- registry-url: 'https://registry.npmjs.org'
- - name: Install deps
- run: pnpm install --frozen-lockfile
- - name: Update npm
- run: npm i -g npm@latest
- - name: Build and publish
- id: publish
- run: |
- pnpm release --publishOnly
- - name: Create GitHub release
- id: release_tag
- uses: yyx990803/release-tag@8cccf7c5aa332d71d222df46677f70f77a8d2dc0 # v1.0.0
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- with:
- tag_name: ${{ github.ref }}
- body: |
- For stable releases, please refer to [CHANGELOG.md](https://github.com/vuejs/core/blob/main/CHANGELOG.md) for details.
- For pre-releases, please refer to [CHANGELOG.md](https://github.com/vuejs/core/blob/minor/CHANGELOG.md) of the `minor` branch.
|