eslint-plugin-woodpecker 1.1.6 → 1.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +117 -9
- package/docs/LICENSE.md +4 -0
- package/package.json +13 -23
- package/src/utils/woodpecker.js +1 -1
- package/src/utils/yaml.js +1 -1
package/README.md
CHANGED
|
@@ -18,7 +18,9 @@ ESLint rules for Woodpecker CI files (including shell commands).
|
|
|
18
18
|
|
|
19
19
|
---
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
<h2 id="installation">
|
|
22
|
+
<img height=30 width=27 align="top" src="https://api.iconify.design/ic/sharp-install-desktop.svg?color=%232b2b2a"> Installation
|
|
23
|
+
</h2>
|
|
22
24
|
|
|
23
25
|
From your project root:
|
|
24
26
|
|
|
@@ -69,17 +71,17 @@ export default [
|
|
|
69
71
|
---
|
|
70
72
|
|
|
71
73
|
<h2 id="disabling-rules">
|
|
72
|
-
<img height=
|
|
74
|
+
<img height=30 width=24 align="top" src="https://api.iconify.design/mdi/cancel.svg?color=%232b2b2a">
|
|
73
75
|
Disabling rules
|
|
74
76
|
</h2>
|
|
75
77
|
|
|
76
|
-
Aside from editing `eslint.config.*js`, rules can also be disabled via <a target="_blank" href="https://eslint.org/docs/latest/use/configure/rules#disable-rules">standard ESLint directives</a
|
|
78
|
+
Aside from editing `eslint.config.*js`, rules can also be disabled via inline YAML comments using <a target="_blank" href="https://eslint.org/docs/latest/use/configure/rules#disable-rules">standard ESLint directives</a>:
|
|
77
79
|
|
|
78
80
|
```yaml
|
|
79
81
|
# eslint-disable woodpecker/require-event-filter
|
|
80
82
|
|
|
81
83
|
steps:
|
|
82
|
-
- name:
|
|
84
|
+
- name: lint
|
|
83
85
|
image: node:26.13.0-alpine@sha256:8996bb5821d62a8fd9bb27c1cb07462f3fdce6e47d640c6a881ead0b064ce216
|
|
84
86
|
commands: # eslint-disable-next-line woodpecker/shellcheck-commands -- `APK_DEPS` unquoted to force multi args
|
|
85
87
|
- apk add --no-cache $${APK_DEPS}
|
|
@@ -90,6 +92,117 @@ steps:
|
|
|
90
92
|
|
|
91
93
|
---
|
|
92
94
|
|
|
95
|
+
<h2 id="integrations">
|
|
96
|
+
<img width=26 align="top" src="https://api.iconify.design/mdi/connection.svg?color=%232b2b2a">
|
|
97
|
+
Integrations
|
|
98
|
+
</h2>
|
|
99
|
+
|
|
100
|
+
<h3 id="ide">
|
|
101
|
+
<img width=16 align=bottom title="VS Code" src="https://www.google.com/s2/favicons?domain=code.visualstudio.com&sz=32">
|
|
102
|
+
<img width=16 align=bottom title="Cursor" src="https://www.google.com/s2/favicons?domain=cursor.com&sz=32">
|
|
103
|
+
<img width=16 align=bottom title="Devin" src="https://www.google.com/s2/favicons?domain=devin.ai&sz=32">
|
|
104
|
+
<img width=16 align=bottom title="VSCodium" src="https://www.google.com/s2/favicons?domain=vscodium.com&sz=32">
|
|
105
|
+
<img width=16 align=bottom title="Antigravity" src="https://www.google.com/s2/favicons?domain=antigravity.google&sz=32">
|
|
106
|
+
<img width=16 align=bottom title="Void" src="https://www.google.com/s2/favicons?domain=voideditor.com&sz=32">
|
|
107
|
+
<img width=16 align=bottom title="Positron" src="https://www.google.com/s2/favicons?domain=positron.posit.co&sz=32">
|
|
108
|
+
<img width=16 align=bottom title="JetBrains" src="https://www.google.com/s2/favicons?domain=jetbrains.com&sz=32">
|
|
109
|
+
<img width=16 align=bottom title="Sublime Text" src="https://www.google.com/s2/favicons?domain=sublimetext.com&sz=32">
|
|
110
|
+
<img width=16 align=bottom title="Neovim" src="https://www.google.com/s2/favicons?domain=neovim.io&sz=32">
|
|
111
|
+
</h3>
|
|
112
|
+
|
|
113
|
+
<details>
|
|
114
|
+
|
|
115
|
+
<summary>Install an <strong>IDE extension</strong> for extended features (e.g. live linting, auto-fix).</summary><br>
|
|
116
|
+
|
|
117
|
+
<table>
|
|
118
|
+
<thead>
|
|
119
|
+
<tr>
|
|
120
|
+
<th align="center">Editor</th>
|
|
121
|
+
<th align="center">ESLint</th>
|
|
122
|
+
</tr>
|
|
123
|
+
</thead>
|
|
124
|
+
<tbody>
|
|
125
|
+
<tr>
|
|
126
|
+
<td align="center"><img width=14 src="https://www.google.com/s2/favicons?domain=code.visualstudio.com&sz=16"> VS Code</td>
|
|
127
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=visualstudio.com&sz=16"> <a target="_blank" href="https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint"><code>dbaeumer.vscode-eslint</code></a></td>
|
|
128
|
+
</tr>
|
|
129
|
+
<tr>
|
|
130
|
+
<td align="center"><img width=14 title="Cursor" src="https://www.google.com/s2/favicons?domain=cursor.com&sz=32"> <img width=14 title="Devin" src="https://www.google.com/s2/favicons?domain=devin.ai&sz=32"> <img width=14 title="VSCodium" src="https://www.google.com/s2/favicons?domain=vscodium.com&sz=32"> VS Code forks</td>
|
|
131
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=open-vsx.org&sz=16"> <a target="_blank" href="https://open-vsx.org/extension/dbaeumer/vscode-eslint"><code>dbaeumer.vscode-eslint</code></a></td>
|
|
132
|
+
</tr>
|
|
133
|
+
<tr>
|
|
134
|
+
<td align="center"><img width=14 src="https://www.google.com/s2/favicons?domain=jetbrains.com&sz=16"> JetBrains</td>
|
|
135
|
+
<td align="center"><img width=14 align=bottom src="https://www.google.com/s2/favicons?domain=jetbrains.com&sz=16"> <a target="_blank" href="https://plugins.jetbrains.com/plugin/25292-eslint"><code>25292-eslint</code></a></td>
|
|
136
|
+
</tr>
|
|
137
|
+
<tr>
|
|
138
|
+
<td align="center"><img width=14 src="https://www.google.com/s2/favicons?domain=sublimetext.com&sz=16"> Sublime Text</td>
|
|
139
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=sublimetext.com&sz=16"> <a target="_blank" href="https://packages.sublimetext.com/packages/LSP-eslint"><code>LSP-eslint</code></a></td>
|
|
140
|
+
</tr>
|
|
141
|
+
<tr>
|
|
142
|
+
<td align="center"><img width=14 src="https://www.google.com/s2/favicons?domain=neovim.io&sz=16"> Neovim</td>
|
|
143
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=npmjs.com&sz=16"> <a target="_blank" href="https://www.npmjs.com/package/coc-eslint"><code>coc-eslint</code></a></td>
|
|
144
|
+
</tr>
|
|
145
|
+
</tbody>
|
|
146
|
+
</table>
|
|
147
|
+
|
|
148
|
+
---
|
|
149
|
+
|
|
150
|
+
</details>
|
|
151
|
+
|
|
152
|
+
<h3 id="ci">
|
|
153
|
+
<img width=16 align=bottom title="Forgejo Actions" src="https://www.google.com/s2/favicons?domain=forgejo.org&sz=32">
|
|
154
|
+
<img width=16 align=bottom title="Woodpecker CI" src="https://www.google.com/s2/favicons?domain=woodpecker-ci.org&sz=32">
|
|
155
|
+
<img width=16 align=bottom title="GitLab CI" src="https://www.google.com/s2/favicons?domain=gitlab.com&sz=32">
|
|
156
|
+
<img width=16 align=bottom title="CircleCI" src="https://www.google.com/s2/favicons?domain=circleci.com&sz=32">
|
|
157
|
+
<img width=16 align=bottom title="TeamCity" src="https://www.google.com/s2/favicons?domain=jetbrains.com&sz=32">
|
|
158
|
+
<img width=16 align=bottom title="GitHub Actions" src="https://www.google.com/s2/favicons?domain=github.com&sz=32">
|
|
159
|
+
</h3>
|
|
160
|
+
|
|
161
|
+
<details>
|
|
162
|
+
|
|
163
|
+
<summary>Use plugins in your <strong>CI pipeline</strong>.</summary><br>
|
|
164
|
+
|
|
165
|
+
<table>
|
|
166
|
+
<thead>
|
|
167
|
+
<tr>
|
|
168
|
+
<th align="center">CI</th>
|
|
169
|
+
<th align="center">ESLint</th>
|
|
170
|
+
</tr>
|
|
171
|
+
</thead>
|
|
172
|
+
<tbody>
|
|
173
|
+
<tr>
|
|
174
|
+
<td align="center"><img width=13 src="https://www.google.com/s2/favicons?domain=forgejo.org&sz=16"> Forgejo Actions<sup><small>1</small></sup></td>
|
|
175
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=forgejo.org&sz=16"> <code>https://github.com/sibiraj-s/action-eslint@v4</code></td>
|
|
176
|
+
</tr>
|
|
177
|
+
<tr>
|
|
178
|
+
<td align="center"><img width=13 src="https://www.google.com/s2/favicons?domain=woodpecker-ci.org&sz=16"> Woodpecker CI</td>
|
|
179
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=woodpecker-ci.org&sz=16"> <a target="_blank" href="https://woodpecker-ci.org/plugins/reviewdog-eslint"><code>reviewdog-eslint</code></a></td>
|
|
180
|
+
</tr>
|
|
181
|
+
<tr>
|
|
182
|
+
<td align="center"><img width=13 src="https://www.google.com/s2/favicons?domain=gitlab.com&sz=16"> GitLab CI</td>
|
|
183
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=gitlab.com&sz=16"> <a target="_blank" href="https://gitlab.com/components/code-quality-oss/codequality-os-scanners-integration"><code>codequality-os-scanners-integration</code></a></td>
|
|
184
|
+
</tr>
|
|
185
|
+
<tr>
|
|
186
|
+
<td align="center"><img width=15 align=bottom src="https://www.google.com/s2/favicons?domain=circleci.com&sz=32"> CircleCI</td>
|
|
187
|
+
<td align="center"><img width=15 align=bottom src="https://www.google.com/s2/favicons?domain=circleci.com&sz=32"> <a target="_blank" href="https://circleci.com/developer/orbs/orb/arrai/eslint"><code>arrai/eslint</code></a></td>
|
|
188
|
+
</tr>
|
|
189
|
+
<tr>
|
|
190
|
+
<td align="center"><img width=13 src="https://www.google.com/s2/favicons?domain=jetbrains.com&sz=16"> TeamCity</td>
|
|
191
|
+
<td align="center"><img width=12 align=bottom src="https://www.google.com/s2/favicons?domain=npmjs.com&sz=16"> <a target="_blank" href="https://www.npmjs.com/package/eslint-formatter-teamcity"><code>eslint-formatter-teamcity</code></a></td>
|
|
192
|
+
</tr>
|
|
193
|
+
<tr>
|
|
194
|
+
<td align="center"><img width=13 src="https://www.google.com/s2/favicons?domain=github.com&sz=16"> GitHub Actions</td>
|
|
195
|
+
<td align="center"><img width=13 align=bottom src="https://www.google.com/s2/favicons?domain=github.com&sz=16"> <a target="_blank" href="https://github.com/marketplace/actions/action-eslint"><code>action-eslint</code></a></td>
|
|
196
|
+
</tr>
|
|
197
|
+
</tbody>
|
|
198
|
+
</table>
|
|
199
|
+
|
|
200
|
+
<small><sup>1</sup> Set the URL as <a target="_blank" href="https://forgejo.org/docs/next/user/actions/reference/#jobsjob_idstepsuses"><code>uses</code></a> to run. For improved security, replace the URL's ver tag w/ a commit hash. </small>
|
|
201
|
+
|
|
202
|
+
</details>
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
93
206
|
<h2 id="supported-rules">
|
|
94
207
|
<img height=30 width=27 align="top" src="https://api.iconify.design/mdi/format-list-checks.svg?color=%232b2b2a">
|
|
95
208
|
Supported rules
|
|
@@ -370,7 +483,6 @@ If you use a modified schema.
|
|
|
370
483
|
#### See also
|
|
371
484
|
|
|
372
485
|
- <img height=12 src="https://www.google.com/s2/favicons?domain=woodpecker-ci.org&sz=64"> <a target="_blank" href="https://woodpecker-ci.org/docs/usage/workflow-syntax">Woodpecker — Workflow syntax</a>
|
|
373
|
-
- <img height=12 src="https://www.google.com/s2/favicons?domain=woodpecker-ci.org&sz=64"> <a target="_blank" href="https://woodpecker-ci.org/docs/cli">Woodpecker — CLI reference</a>
|
|
374
486
|
|
|
375
487
|
<div align="center">
|
|
376
488
|
|
|
@@ -404,10 +516,6 @@ If you use a modified schema.
|
|
|
404
516
|
|
|
405
517
|
## <img height=30 width=27 align="top" src="https://api.iconify.design/ic/baseline-account-balance.svg?color=%232b2b2a"> License
|
|
406
518
|
|
|
407
|
-
<a href="https://codeberg.org/adamlui/eslint-plugin-woodpecker/src/branch/main/docs/LICENSE.md">
|
|
408
|
-
<img height=88 src="https://cdn.staticdelivr.com/gl/adamlui/eslint-plugin-chrome-extensions/d79e1db7e2/assets/images/banners/mit-license/banner.png"></a>
|
|
409
|
-
<br><br>
|
|
410
|
-
|
|
411
519
|
<details>
|
|
412
520
|
|
|
413
521
|
<summary>Copyright © 2026 <a target="_blank" href="https://codeberg.org/adamlui"><b>Adam Lui</b></a> under the <a target="_blank" href="https://codeberg.org/adamlui/eslint-plugin-woodpecker/src/branch/main/docs/LICENSE.md"><b>MIT license</b></a>.</summary><br>
|
package/docs/LICENSE.md
CHANGED
|
@@ -7,3 +7,7 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
|
7
7
|
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
8
8
|
|
|
9
9
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
SPDX-License-Identifier: MIT
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eslint-plugin-woodpecker",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.8",
|
|
4
4
|
"description": "ESLint rules for Woodpecker CI files (including shell commands)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ci",
|
|
@@ -59,14 +59,14 @@
|
|
|
59
59
|
"test": "node tests/run"
|
|
60
60
|
},
|
|
61
61
|
"overrides": {
|
|
62
|
-
"@eslint/
|
|
63
|
-
"
|
|
62
|
+
"@eslint/markdown": {
|
|
63
|
+
"katex": "^0.19.1"
|
|
64
64
|
},
|
|
65
|
-
"
|
|
66
|
-
"minimatch": "^11.0.
|
|
65
|
+
"eslint": {
|
|
66
|
+
"minimatch": "^11.0.9"
|
|
67
67
|
},
|
|
68
|
-
"eslint-plugin-
|
|
69
|
-
"minimatch": "^11.0.
|
|
68
|
+
"eslint-plugin-import-x": {
|
|
69
|
+
"minimatch": "^11.0.9"
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
72
|
"dependencies": {
|
|
@@ -74,25 +74,15 @@
|
|
|
74
74
|
"yaml": "^2.9.1"
|
|
75
75
|
},
|
|
76
76
|
"devDependencies": {
|
|
77
|
-
"@e18e/eslint-plugin": "^0.8.1",
|
|
78
77
|
"@eslint/json": "^2.1.1",
|
|
79
|
-
"@eslint/markdown": "^
|
|
80
|
-
"@
|
|
81
|
-
"@typescript-eslint/
|
|
82
|
-
"
|
|
83
|
-
"eslint": "^
|
|
84
|
-
"eslint-plugin-constructors": "^1.7.1",
|
|
85
|
-
"eslint-plugin-eslint-plugin": "^7.6.2",
|
|
86
|
-
"eslint-plugin-import-x": "^4.18.0",
|
|
87
|
-
"eslint-plugin-n": "^18.5.0",
|
|
78
|
+
"@eslint/markdown": "^9.0.0",
|
|
79
|
+
"@typescript-eslint/parser": "^8.73.0",
|
|
80
|
+
"@typescript-eslint/utils": "^8.73.0",
|
|
81
|
+
"eslint": "^10.15.0",
|
|
82
|
+
"eslint-plugin-import-x": "^4.18.1",
|
|
88
83
|
"eslint-plugin-no-secrets": "^2.3.3",
|
|
89
|
-
"eslint-plugin-no-unsanitized": "^4.1.5",
|
|
90
84
|
"eslint-plugin-package-json": "^1.14.0",
|
|
91
|
-
"
|
|
92
|
-
"eslint-plugin-regexp": "^3.3.3",
|
|
93
|
-
"eslint-plugin-security": "^4.2.1",
|
|
94
|
-
"eslint-plugin-sonarjs": "^4.2.2",
|
|
95
|
-
"oxlint": "^1.92.0",
|
|
85
|
+
"oxlint": "^1.94.0",
|
|
96
86
|
"typescript": "npm:@typescript/typescript6@^6.0.2",
|
|
97
87
|
"typescript-latest": "npm:typescript@^7.0.2"
|
|
98
88
|
},
|
package/src/utils/woodpecker.js
CHANGED
|
@@ -29,7 +29,7 @@ export default {
|
|
|
29
29
|
|
|
30
30
|
getWhen(when) {
|
|
31
31
|
if (!when) return null
|
|
32
|
-
else if (Array.isArray(when)) return when.map(
|
|
32
|
+
else if (Array.isArray(when)) return when.map(entry => this.getWhen(entry)).find(Boolean) || null
|
|
33
33
|
else if (typeof when != 'object') return null
|
|
34
34
|
else if (typeof when.event == 'string' || Array.isArray(when.event)) return when
|
|
35
35
|
else return null
|
package/src/utils/yaml.js
CHANGED