Skip to content

Commit 49b8379

Browse files
chore: sync workflows
1 parent 395260b commit 49b8379

File tree

7 files changed

+32
-17
lines changed

7 files changed

+32
-17
lines changed

.github/workflow-settings.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,13 @@
55
"update wp version",
66
"trigger workflow",
77
"update TOC"
8-
]
8+
],
9+
"PROJECT": "Backlog",
10+
"ISSUE_COLUMN": "To do",
11+
"PR_COLUMN": "In progress",
12+
"PR_BODY_TITLE": "## Changes",
13+
"TOC_FOLDING": "1",
14+
"TOC_MAX_HEADER_LEVEL": "3",
15+
"TOC_TITLE": "Details",
16+
"BRANCH_PREFIX": "release/"
917
}

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ jobs:
8181
run: echo "::set-env name=RUNNING::"
8282
if: "! env.GIT_DIFF"
8383
- name: Set running flag
84-
if: matrix.node == '12' && github.ref == format('refs/heads/{0}', github.event.repository.default_branch)
84+
if: "matrix.node == '12' && ! startsWith(github.ref, 'refs/tags/') && github.event.base_ref == format('refs/heads/{0}', github.event.repository.default_branch)"
8585
run: echo "::set-env name=RUNNING::1"
8686
- name: Set running flag
8787
if: matrix.node == '12' && startsWith(github.ref, 'refs/tags/v')
@@ -232,7 +232,7 @@ jobs:
232232
env:
233233
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
234234
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
235-
if: success()
235+
if: success() && env.SLACK_WEBHOOK_URL
236236

237237
slack:
238238
name: Slack
@@ -247,4 +247,4 @@ jobs:
247247
env:
248248
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
249249
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
250-
if: env.WORKFLOW_CONCLUSION == 'failure'
250+
if: env.WORKFLOW_CONCLUSION == 'failure' && env.SLACK_WEBHOOK_URL

.github/workflows/issue-opened.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,13 @@ jobs:
99
name: Assign issues to project
1010
runs-on: ubuntu-latest
1111
steps:
12+
- uses: technote-space/load-config-action@v1
13+
with:
14+
CONFIG_FILENAME: workflow-settings.json
1215
- uses: technote-space/create-project-card-action@v1
1316
with:
14-
PROJECT: Backlog
15-
COLUMN: To do
17+
PROJECT: ${{ env.PROJECT }}
18+
COLUMN: ${{ env.ISSUE_COLUMN }}
1619

1720
assignAuthor:
1821
name: Assign author to issue

.github/workflows/pr-opened.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,13 @@ jobs:
1010
name: Assign PullRequest to Project
1111
runs-on: ubuntu-latest
1212
steps:
13+
- uses: technote-space/load-config-action@v1
14+
with:
15+
CONFIG_FILENAME: workflow-settings.json
1316
- uses: technote-space/create-project-card-action@v1
1417
with:
15-
PROJECT: Backlog
16-
COLUMN: In progress
18+
PROJECT: ${{ env.PROJECT }}
19+
COLUMN: ${{ env.PR_COLUMN }}
1720
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
1821

1922
assignAuthor:
@@ -26,4 +29,4 @@ jobs:
2629
name: PR Labeler
2730
runs-on: ubuntu-latest
2831
steps:
29-
- uses: technote-space/pr-labeler-action@v3
32+
- uses: technote-space/pr-labeler-action@v4

.github/workflows/pr-updated.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
- uses: technote-space/pr-commit-body-action@v1
2424
with:
2525
EXCLUDE_MESSAGES: ${{ env.EXCLUDE_MESSAGES }}
26-
TITLE: '## Changes'
26+
TITLE: ${{ env.PR_BODY_TITLE }}
2727
LINK_ISSUE_KEYWORD: ${{ (startsWith(github.head_ref, 'release/') && 'closes') || '' }}
2828
FILTER_PR: true
2929

.github/workflows/toc.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,13 @@ jobs:
1010
name: TOC Generator
1111
runs-on: ubuntu-latest
1212
steps:
13+
- uses: technote-space/load-config-action@v1
14+
with:
15+
CONFIG_FILENAME: workflow-settings.json
1316
- uses: technote-space/toc-generator@v2
1417
with:
1518
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
16-
TARGET_BRANCH_PREFIX: release/
17-
FOLDING: true
18-
MAX_HEADER_LEVEL: 3
19-
TOC_TITLE: Details
19+
TARGET_BRANCH_PREFIX: ${{ env.BRANCH_PREFIX }}
20+
FOLDING: ${{ env.TOC_FOLDING }}
21+
MAX_HEADER_LEVEL: ${{ env.TOC_MAX_HEADER_LEVEL }}
22+
TOC_TITLE: ${{ env.TOC_TITLE }}

.github/workflows/update-dependencies.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
EXCLUDE_MERGED: 'true'
2121
- name: Update dependencies
2222
id: update_deps
23-
uses: technote-space/create-pr-action@v1
23+
uses: technote-space/create-pr-action@v2
2424
with:
2525
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
2626
EXECUTE_COMMANDS: |
@@ -29,8 +29,6 @@ jobs:
2929
yarn upgrade
3030
yarn audit
3131
COMMIT_MESSAGE: 'chore: update npm dependencies'
32-
PR_BRANCH_NAME: 'chore-npm-update-${PR_ID}'
33-
PR_TITLE: 'chore: update npm dependencies (${PR_MERGE_REF})'
3432
PR_DEFAULT_BRANCH_PREFIX: release/
3533
PR_DEFAULT_BRANCH_NAME: next-${CURRENT_VERSION}
3634
PR_DEFAULT_BRANCH_TITLE: 'feat: release'

0 commit comments

Comments
 (0)