Skip to content

Commit 0e47c9c

Browse files
authored
Update release-please.yml
1 parent a00cf0e commit 0e47c9c

File tree

1 file changed

+9
-37
lines changed

1 file changed

+9
-37
lines changed
Lines changed: 9 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,24 @@
11
name: release-please
22
on:
3-
push:
4-
branches: [ dev ]
53
workflow_dispatch:
4+
#push:
5+
# branches:
6+
# - 5.x
7+
permissions:
8+
contents: write
9+
issues: write
10+
pull-requests: write
611

712
jobs:
813
release-please:
914
if: github.repository == 'volantis-x/hexo-theme-volantis'
1015
runs-on: ubuntu-latest
1116
steps:
12-
- uses: google-github-actions/release-please-action@v3
17+
- uses: googleapis/release-please-action@v4
1318
with:
1419
release-type: node
1520
package-name: hexo-theme-volantis
1621
include-v-in-tag: false
17-
default-branch: dev
18-
19-
# 过时的 publish actions 不再起作用
20-
# npm-publish:
21-
# if: ${{ contains(github.event.head_commit.message, 'chore(dev)') && contains(github.event.head_commit.message, 'release') && github.repository == 'volantis-x/hexo-theme-volantis' }}
22-
# runs-on: ubuntu-latest
23-
# steps:
24-
# - uses: actions/checkout@v4
25-
# - uses: actions/setup-node@v4
26-
# with:
27-
# node-version: 16
28-
# registry-url: https://registry.npmjs.org
29-
# - name: Publish
30-
# run: |
31-
# npm publish
32-
# env:
33-
# NODE_AUTH_TOKEN: ${{ secrets.npm_token }}
34-
22+
target-branch: 5.x
3523

3624

37-
merge:
38-
if: ${{ contains(github.event.head_commit.message, 'chore(dev)') && contains(github.event.head_commit.message, 'release') && github.repository == 'volantis-x/hexo-theme-volantis' }}
39-
runs-on: ubuntu-latest
40-
steps:
41-
- name: merge-to-main
42-
run: |
43-
git config --global user.email "github-actions[bot]@users.noreply.github.com"
44-
git config --global user.name "github-actions[bot]"
45-
git clone https://github.com/volantis-x/hexo-theme-volantis.git hexo-theme-volantis
46-
cd hexo-theme-volantis
47-
git fetch --all
48-
git checkout main
49-
git reset --hard dc9134662502ed2aa8d39dfa09ffe81650a2b024
50-
git merge origin/dev
51-
git push --force "https://github-actions[bot]:${{ secrets.GITHUB_TOKEN }}@github.com/volantis-x/hexo-theme-volantis.git" main:main
52-

0 commit comments

Comments
 (0)