Skip to content
This repository was archived by the owner on Aug 1, 2021. It is now read-only.

Commit ab0a824

Browse files
chore: sync workflows
1 parent 0497921 commit ab0a824

File tree

2 files changed

+41
-5
lines changed

2 files changed

+41
-5
lines changed
Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
on:
22
pull_request:
3-
types: [opened]
3+
types: [synchronize]
44

55
name: Check version
66

@@ -10,20 +10,27 @@ jobs:
1010
runs-on: ubuntu-latest
1111
if: startsWith(github.head_ref, 'release/')
1212
steps:
13+
- uses: technote-space/load-config-action@v1
14+
with:
15+
CONFIG_FILENAME: workflow-settings.json
1316
- name: Set running flag
1417
run: echo "::set-env name=RUNNING::1"
1518
- uses: actions/checkout@v2
16-
- uses: technote-space/get-git-comment-action@v1
1719
- name: Set running flag
1820
run: |
1921
if [[ ! -f readme.txt ]]; then
2022
echo "::set-env name=RUNNING::"
2123
fi
2224
23-
- name: Check version
25+
- name: Get version
26+
uses: technote-space/get-next-version-action@v1
27+
with:
28+
EXCLUDE_MESSAGES: ${{ env.EXCLUDE_MESSAGES }}
29+
if: env.RUNNING
30+
- name: Check package version
2431
uses: technote-space/wp-version-check-action@v1
2532
with:
2633
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
2734
BRANCH_PREFIX: release/
28-
IGNORE_CONTEXT_CHECK: true
29-
if: env.RUNNING
35+
NEXT_VERSION: ${{ env.NEXT_VERSION }}
36+
if: env.NEXT_VERSION

.github/workflows/update-dependencies.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,14 @@ jobs:
1818
name: Update dependencies
1919
runs-on: ubuntu-latest
2020
steps:
21+
- uses: technote-space/load-config-action@v1
22+
with:
23+
CONFIG_FILENAME: workflow-settings.json
2124
- uses: technote-space/auto-cancel-redundant-job@v1
2225
with:
2326
EXCLUDE_MERGED: 'true'
2427
- name: Update dependencies
28+
id: update_deps
2529
uses: technote-space/create-pr-action@v2
2630
with:
2731
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
@@ -34,3 +38,28 @@ jobs:
3438
PR_DEFAULT_BRANCH_TITLE: 'feat: release'
3539
TARGET_BRANCH_PREFIX: release/
3640
AUTO_MERGE_THRESHOLD_DAYS: 14
41+
42+
- name: Set running flag
43+
run: echo "::set-env name=RUNNING::"
44+
- name: Set running flag
45+
run: echo "::set-env name=RUNNING::1"
46+
if: steps.update_deps.outputs.result != 'succeeded' && github.event_name == 'pull_request' && github.event.action != 'closed' && github.event.pull_request.head.user.id == github.event.pull_request.base.user.id && startsWith(github.head_ref, 'release/')
47+
- uses: actions/checkout@v2
48+
if: env.RUNNING
49+
- name: Set running flag
50+
run: |
51+
if [[ ! -f readme.txt ]]; then
52+
echo "::set-env name=RUNNING::"
53+
fi
54+
- name: Get version
55+
uses: technote-space/get-next-version-action@v1
56+
with:
57+
EXCLUDE_MESSAGES: ${{ env.EXCLUDE_MESSAGES }}
58+
if: env.RUNNING
59+
- name: Check package version
60+
uses: technote-space/wp-version-check-action@v1
61+
with:
62+
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
63+
BRANCH_PREFIX: release/
64+
NEXT_VERSION: ${{ env.NEXT_VERSION }}
65+
if: env.NEXT_VERSION

0 commit comments

Comments
 (0)