-
Notifications
You must be signed in to change notification settings - Fork 26
42 lines (40 loc) · 1.24 KB
/
release-dispatch.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: release-dispatch
on:
workflow_dispatch:
inputs:
version:
description: Version to release
required: true
type: string
jobs:
propose-release:
permissions:
pull-requests: write
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org/"
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9.7.0
- name: Update Workspace Packages Version
run: |
VERSION=${{ github.event.inputs.version }}
pnpm -r exec -- bash -c "npm version $VERSION --no-git-tag-version"
- name: Create Pull Request
uses: peter-evans/create-pull-request@v5
with:
token: ${{ secrets.CREATE_PR_TOKEN }}
title: "Prepare release: ${{ github.event.inputs.version }}"
commit-message: "Prepare release: ${{ github.event.inputs.version }}"
branch: "prepare-release"
base: main
delete-branch: true