Skip to content

Commit a5c0446

Browse files
committed
Merge remote-tracking branch 'upstream/master'
2 parents 31dfe56 + ff9c6a9 commit a5c0446

File tree

3 files changed

+26
-13
lines changed

3 files changed

+26
-13
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/.github/ @tinymins

.github/workflows/lint.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,13 @@ name: Lint
33
on:
44
push:
55
pull_request:
6+
workflow_dispatch:
7+
inputs:
8+
ref:
9+
description: 'Branch or tag to lint'
10+
required: false
11+
default: ''
12+
type: string
613

714
jobs:
815
lint:
@@ -14,6 +21,7 @@ jobs:
1421
- uses: actions/checkout@v4
1522
with:
1623
fetch-depth: 0
24+
ref: ${{ github.event.inputs.ref || github.ref }}
1725

1826
- name: Set up Python 3.10
1927
uses: actions/setup-python@v3

.github/workflows/publish.yml

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -104,23 +104,27 @@ jobs:
104104
run: |
105105
python3 \!src-dist/ci.py
106106
107-
- name: Push commits
107+
- name: Create Release Branch
108108
run: |
109+
VERSION="${{ github.event.inputs.version }}"
110+
BRANCH="release/v${VERSION}"
109111
git push -f origin master:stable
112+
git push -f origin master:$BRANCH
110113
111-
- name: Create release branch and PR
112-
env:
113-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
114+
- name: Create Pull Request
115+
id: create_pr
116+
uses: peter-evans/create-pull-request@v5
117+
with:
118+
token: ${{ secrets.PAT_TOKEN || secrets.GITHUB_TOKEN }}
119+
title: "release: v${{ github.event.inputs.version }}"
120+
body: "Automated release PR for version ${{ github.event.inputs.version }}"
121+
base: master
122+
branch: "release/v${{ github.event.inputs.version }}"
123+
124+
- name: Output PR URL
125+
if: steps.create_pr.outputs.pull-request-url
114126
run: |
115-
VERSION="${{ github.event.inputs.version }}"
116-
BRANCH="release/v${VERSION}"
117-
git checkout -b $BRANCH
118-
git push -u origin $BRANCH -f
119-
gh pr create \
120-
--title "release: v${VERSION}" \
121-
--body "Automated release PR for version ${VERSION}" \
122-
--base master \
123-
--head $BRANCH || echo "PR already exists or failed to create, continuing..."
127+
echo "::notice::Pull Request created: ${{ steps.create_pr.outputs.pull-request-url }}"
124128
125129
- name: Upload Artifacts
126130
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)