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

Commit 3328966

Browse files
Merge pull request #59 from technote-space/chore/chore-sync-workflows
chore: sync workflows
2 parents ebfac7b + a156618 commit 3328966

9 files changed

+74
-10
lines changed

.github/workflow-settings.json

+9-1
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,13 @@
1414
"TOC_MAX_HEADER_LEVEL": "3",
1515
"TOC_TITLE": "Details",
1616
"TOC_CREATE_PR": "true",
17-
"BRANCH_PREFIX": "release/"
17+
"TOC_TARGET_PATHS": "README*.md",
18+
"BRANCH_PREFIX": "release/",
19+
"ANNOTATION_EXCLUDE_PATTERNS": [
20+
"warning jest",
21+
"warning babel-jest",
22+
"Cloning into",
23+
"has unmet peer dependency",
24+
"has incorrect peer dependency"
25+
]
1826
}

.github/workflows/add-release-tag.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ jobs:
1717
steps:
1818
- uses: technote-space/load-config-action@v1
1919
with:
20-
CONFIG_FILENAME: workflow-settings.json
20+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
21+
IGNORE_WARNING: 'true'
2122
- name: Get version
2223
uses: technote-space/get-next-version-action@v1
2324
with:

.github/workflows/add-test-tag.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ jobs:
1313
steps:
1414
- uses: technote-space/load-config-action@v1
1515
with:
16-
CONFIG_FILENAME: workflow-settings.json
16+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
17+
IGNORE_WARNING: 'true'
1718
- uses: actions/checkout@v2
1819
- uses: technote-space/get-git-comment-action@v1
1920
- name: Get version

.github/workflows/check-warnings.yml

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
on:
2+
workflow_run:
3+
workflows:
4+
- CI
5+
- Sync workflows
6+
- Update dependencies
7+
- Broken Link Check
8+
types:
9+
- completed
10+
11+
name: Check Warnings
12+
13+
jobs:
14+
annotations:
15+
name: Annotations
16+
runs-on: ubuntu-latest
17+
timeout-minutes: 3
18+
steps:
19+
- uses: technote-space/load-config-action@v1
20+
with:
21+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
22+
IGNORE_WARNING: 'true'
23+
- uses: technote-space/download-annotations-action@v1
24+
id: annotations
25+
with:
26+
TARGET_RUN_ID: ${{ github.event.workflow_run.id }}
27+
INCLUDE_LEVELS: warning
28+
EXCLUDE_MESSAGE_PATTERNS: ${{ env.ANNOTATION_EXCLUDE_PATTERNS }}
29+
- name: Build attachments
30+
run: |
31+
arr1='[{"fields":[{"title":"repo","value":"<https://github.com/${{ github.repository }}|${{ github.repository }}>","short":true},{"title":"action","value":"<${{ github.event.workflow_run.html_url }}|summary>","short":true}]}]'
32+
arr2=$(echo '${{ steps.annotations.outputs.messages }}' | jq -c 'map({"color":"warning","text":"```\(.)```"})')
33+
echo "SLACK_ATTACHMENTS=$(jq --argjson arr1 "$arr1" --argjson arr2 "$arr2" -nc '$arr1 + $arr2')" >> $GITHUB_ENV
34+
if: steps.annotations.outputs.number > 0
35+
- uses: 8398a7/action-slack@v3
36+
with:
37+
status: custom
38+
fields: repo
39+
custom_payload: |
40+
{
41+
text: "Warning annotations",
42+
attachments: ${{ env.SLACK_ATTACHMENTS }}
43+
}
44+
env:
45+
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
46+
if: steps.annotations.outputs.number > 0 && env.SLACK_WEBHOOK_URL

.github/workflows/issue-opened.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ jobs:
1212
steps:
1313
- uses: technote-space/load-config-action@v1
1414
with:
15-
CONFIG_FILENAME: workflow-settings.json
15+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
16+
IGNORE_WARNING: 'true'
1617
- uses: technote-space/create-project-card-action@v1
1718
with:
1819
PROJECT: ${{ env.PROJECT }}

.github/workflows/pr-opened.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ jobs:
1212
steps:
1313
- uses: technote-space/load-config-action@v1
1414
with:
15-
CONFIG_FILENAME: workflow-settings.json
15+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
16+
IGNORE_WARNING: 'true'
1617
- uses: technote-space/create-project-card-action@v1
1718
with:
1819
PROJECT: ${{ env.PROJECT }}

.github/workflows/pr-updated.yml

+6-3
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ jobs:
2121
steps:
2222
- uses: technote-space/load-config-action@v1
2323
with:
24-
CONFIG_FILENAME: workflow-settings.json
24+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
25+
IGNORE_WARNING: 'true'
2526
- uses: technote-space/pr-commit-body-action@v1
2627
with:
2728
EXCLUDE_MESSAGES: ${{ env.EXCLUDE_MESSAGES }}
@@ -37,7 +38,8 @@ jobs:
3738
steps:
3839
- uses: technote-space/load-config-action@v1
3940
with:
40-
CONFIG_FILENAME: workflow-settings.json
41+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
42+
IGNORE_WARNING: 'true'
4143
- uses: technote-space/release-type-action@v1
4244
with:
4345
EXCLUDE_MESSAGES: ${{ env.EXCLUDE_MESSAGES }}
@@ -51,7 +53,8 @@ jobs:
5153
steps:
5254
- uses: technote-space/load-config-action@v1
5355
with:
54-
CONFIG_FILENAME: workflow-settings.json
56+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
57+
IGNORE_WARNING: 'true'
5558
- name: Set running flag
5659
run: echo "RUNNING=1" >> $GITHUB_ENV
5760
- uses: actions/checkout@v2

.github/workflows/toc.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ jobs:
1313
steps:
1414
- uses: technote-space/load-config-action@v1
1515
with:
16-
CONFIG_FILENAME: workflow-settings.json
16+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
17+
IGNORE_WARNING: 'true'
1718
- uses: technote-space/toc-generator@v3
1819
with:
1920
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
@@ -22,3 +23,4 @@ jobs:
2223
MAX_HEADER_LEVEL: ${{ env.TOC_MAX_HEADER_LEVEL }}
2324
TOC_TITLE: ${{ env.TOC_TITLE }}
2425
CREATE_PR: ${{ env.TOC_CREATE_PR }}
26+
TARGET_PATHS: ${{ env.TOC_TARGET_PATHS }}

.github/workflows/update-dependencies.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ jobs:
2323
- uses: technote-space/load-config-action@v1
2424
if: env.RUNNING1
2525
with:
26-
CONFIG_FILENAME: workflow-settings.json
26+
CONFIG_FILENAME: workflow-settings.json, workflow-details.json
27+
IGNORE_WARNING: 'true'
2728
- uses: technote-space/auto-cancel-redundant-workflow@gh-actions
2829
if: env.RUNNING1
2930
with:

0 commit comments

Comments
 (0)