Skip to content

Commit

Permalink
add workflow to lint workflow files
Browse files Browse the repository at this point in the history
  • Loading branch information
capnspacehook committed Oct 29, 2022
1 parent e1f946e commit 929be5b
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 1 deletion.
17 changes: 17 additions & 0 deletions .github/actionlint-matcher.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"problemMatcher": [
{
"owner": "actionlint",
"pattern": [
{
"regexp": "^(?:\\x1b\\[\\d+m)?(.+?)(?:\\x1b\\[\\d+m)*:(?:\\x1b\\[\\d+m)*(\\d+)(?:\\x1b\\[\\d+m)*:(?:\\x1b\\[\\d+m)*(\\d+)(?:\\x1b\\[\\d+m)*: (?:\\x1b\\[\\d+m)*(.+?)(?:\\x1b\\[\\d+m)* \\[(.+?)\\]$",
"file": 1,
"line": 2,
"column": 3,
"message": 4,
"code": 5
}
]
}
]
}
29 changes: 29 additions & 0 deletions .github/workflows/lint-actions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Lint workflows

on:
push:
paths:
- ".github/workflows/*"

env:
GO_VERSION: "1.19"

jobs:
lint-workflows:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Install Go
uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}.x
check-latest: true
cache: true

- name: Lint workflow files
run: |
echo "::add-matcher::.github/actionlint-matcher.json"
go install github.com/rhysd/actionlint/cmd/actionlint@latest
actionlint
2 changes: 1 addition & 1 deletion .github/workflows/vuln.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Vuln
name: Vulnerability scan

on:
push:
Expand Down

0 comments on commit 929be5b

Please # to comment.