@@ -27,10 +27,12 @@ jobs:
27
27
steps :
28
28
- name : Checkout Repository
29
29
uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
30
+
30
31
- name : Setup Golang Environment
31
32
uses : actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1
32
33
with :
33
34
go-version-file : go.mod
35
+
34
36
- name : Lint Code
35
37
uses : golangci/golangci-lint-action@639cd343e1d3b897ff35927a75193d57cfcba299 # v3.6.0
36
38
with :
@@ -43,21 +45,35 @@ jobs:
43
45
steps :
44
46
- name : Checkout Repository
45
47
uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
48
+
46
49
- name : Get Prettier version
47
50
id : prettier-version
48
51
run : |
49
52
echo "version=$(jq -r .devDependencies.prettier ${{ github.workspace }}/internal/nginx/modules/package.json)" >> $GITHUB_OUTPUT
53
+
50
54
- name : Run Prettier on NJS code
51
55
id : prettier-run
52
56
uses : rutajdash/prettier-cli-action@9e27606a9e18d40b6b4a2b4159e780241d2fbb3c # v1.0.1
53
57
with :
54
58
config_path : ${{ github.workspace }}/internal/nginx/modules/.prettierrc
55
59
file_pattern : ${{ github.workspace }}/internal/nginx/modules/**/*.js
56
60
prettier_version : ${{ steps.prettier-version.outputs.version }}
61
+
57
62
- name : Prettier Output
58
63
if : failure()
59
64
shell : bash
60
65
run : |
61
66
echo "The following files are not formatted:"
62
67
echo "${{steps.prettier-run.outputs.prettier_output}}"
63
68
echo "Run \"make njs-fmt\" locally to format the code"
69
+
70
+ actionlint :
71
+ name : Actionlint
72
+ runs-on : ubuntu-22.04
73
+ steps :
74
+ - name : Checkout Repository
75
+ uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
76
+
77
+ - uses : reviewdog/action-actionlint@42de1e3a0f52d5f8b8390894de87bc603844e530 # v1.37.0
78
+ with :
79
+ actionlint_flags : -shellcheck ""
0 commit comments