Skip to content

Commit 245527a

Browse files
committed
Merge remote-tracking branch 'upstream/master'
2 parents 5266f0a + 4512585 commit 245527a

File tree

12 files changed

+48243
-43790
lines changed

12 files changed

+48243
-43790
lines changed

.eslintrc.json

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"plugins": ["jest", "@typescript-eslint"],
3-
"extends": ["plugin:github/es6"],
3+
"extends": ["plugin:github/internal"],
44
"parser": "@typescript-eslint/parser",
55
"parserOptions": {
66
"ecmaVersion": 9,
@@ -16,13 +16,10 @@
1616
"@typescript-eslint/no-require-imports": "error",
1717
"@typescript-eslint/array-type": "error",
1818
"@typescript-eslint/await-thenable": "error",
19-
"@typescript-eslint/ban-ts-ignore": "error",
2019
"camelcase": "off",
2120
"@typescript-eslint/camelcase": "off",
22-
"@typescript-eslint/class-name-casing": "error",
2321
"@typescript-eslint/explicit-function-return-type": ["error", {"allowExpressions": true}],
2422
"@typescript-eslint/func-call-spacing": ["error", "never"],
25-
"@typescript-eslint/generic-type-naming": ["error", "^[A-Z][A-Za-z]*$"],
2623
"@typescript-eslint/no-array-constructor": "error",
2724
"@typescript-eslint/no-empty-interface": "error",
2825
"@typescript-eslint/no-explicit-any": "off",
@@ -32,15 +29,13 @@
3229
"@typescript-eslint/no-misused-new": "error",
3330
"@typescript-eslint/no-namespace": "error",
3431
"@typescript-eslint/no-non-null-assertion": "warn",
35-
"@typescript-eslint/no-object-literal-type-assertion": "error",
3632
"@typescript-eslint/no-unnecessary-qualifier": "error",
3733
"@typescript-eslint/no-unnecessary-type-assertion": "error",
3834
"@typescript-eslint/no-useless-constructor": "error",
3935
"@typescript-eslint/no-var-requires": "error",
4036
"@typescript-eslint/prefer-for-of": "warn",
4137
"@typescript-eslint/prefer-function-type": "warn",
4238
"@typescript-eslint/prefer-includes": "error",
43-
"@typescript-eslint/prefer-interface": "error",
4439
"@typescript-eslint/prefer-string-starts-ends-with": "error",
4540
"@typescript-eslint/promise-function-async": ["error", { "allowAny": true }],
4641
"@typescript-eslint/require-array-sort-compare": "error",

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,15 @@ jobs:
99
build:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v3
1313
- run: |
1414
npm install
1515
npm run all
1616
1717
self-test:
1818
runs-on: ubuntu-latest
1919
steps:
20-
- uses: actions/checkout@v2
20+
- uses: actions/checkout@v3
2121
- uses: ./
2222
id: filter
2323
with:

.github/workflows/pull-request-verification.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,17 @@ jobs:
1010
build:
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v2
13+
- uses: actions/checkout@v3
1414
- run: |
1515
npm install
1616
npm run all
1717
1818
test-inline:
1919
runs-on: ubuntu-latest
20+
permissions:
21+
pull-requests: read
2022
steps:
21-
- uses: actions/checkout@v2
23+
- uses: actions/checkout@v3
2224
- uses: ./
2325
id: filter
2426
with:
@@ -36,8 +38,10 @@ jobs:
3638

3739
test-external:
3840
runs-on: ubuntu-latest
41+
permissions:
42+
pull-requests: read
3943
steps:
40-
- uses: actions/checkout@v2
44+
- uses: actions/checkout@v3
4145
- uses: ./
4246
id: filter
4347
with:
@@ -49,7 +53,7 @@ jobs:
4953
test-without-token:
5054
runs-on: ubuntu-latest
5155
steps:
52-
- uses: actions/checkout@v2
56+
- uses: actions/checkout@v3
5357
- uses: ./
5458
id: filter
5559
with:
@@ -62,7 +66,7 @@ jobs:
6266
test-wd-without-token:
6367
runs-on: ubuntu-latest
6468
steps:
65-
- uses: actions/checkout@v2
69+
- uses: actions/checkout@v3
6670
with:
6771
path: somewhere
6872
- uses: ./somewhere
@@ -78,7 +82,7 @@ jobs:
7882
test-local-changes:
7983
runs-on: ubuntu-latest
8084
steps:
81-
- uses: actions/checkout@v2
85+
- uses: actions/checkout@v3
8286
- run: echo "NEW FILE" > local
8387
- run: git add local
8488
- uses: ./
@@ -98,7 +102,7 @@ jobs:
98102
test-change-type:
99103
runs-on: ubuntu-latest
100104
steps:
101-
- uses: actions/checkout@v2
105+
- uses: actions/checkout@v3
102106
- name: configure GIT user
103107
run: git config user.email "[email protected]" && git config user.name "John Doe"
104108
- name: modify working tree

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
# Changelog
22

3+
## v2.11.1
4+
- [Update @actions/core to v1.10.0 - Fixes warning about deprecated set-output](https://github.com/dorny/paths-filter/pull/167)
5+
- [Document need for pull-requests: read permission](https://github.com/dorny/paths-filter/pull/168)
6+
- [Updating to actions/checkout@v3](https://github.com/dorny/paths-filter/pull/164)
7+
8+
## v2.11.0
9+
- [Set list-files input parameter as not required](https://github.com/dorny/paths-filter/pull/157)
10+
- [Update Node.js](https://github.com/dorny/paths-filter/pull/161)
11+
- [Fix incorrect handling of Unicode characters in exec()](https://github.com/dorny/paths-filter/pull/162)
12+
- [Use Octokit pagination](https://github.com/dorny/paths-filter/pull/163)
13+
- [Updates real world links](https://github.com/dorny/paths-filter/pull/160)
14+
315
## v2.10.2
416
- [Fix getLocalRef() returns wrong ref](https://github.com/dorny/paths-filter/pull/91)
517

README.md

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ don't allow this because they don't work on a level of individual jobs or steps.
99

1010
**Real world usage examples:**
1111

12-
- [sentry.io](https://sentry.io/) - [backend-test-py3.6.yml](https://github.com/getsentry/sentry/blob/ca0e43dc5602a9ab2e06d3f6397cc48fb5a78541/.github/workflows/backend-test-py3.6.yml#L32)
13-
- [GoogleChrome/web.dev](https://web.dev/) - [lint-and-test-workflow.yml](https://github.com/GoogleChrome/web.dev/blob/e1f0c28964e99ce6a996c1e3fd3ee1985a7a04f6/.github/workflows/lint-and-test-workflow.yml#L33)
12+
- [sentry.io](https://sentry.io/) - [backend.yml](https://github.com/getsentry/sentry/blob/2ebe01feab863d89aa7564e6d243b6d80c230ddc/.github/workflows/backend.yml#L36)
13+
- [GoogleChrome/web.dev](https://web.dev/) - [lint-workflow.yml](https://github.com/GoogleChrome/web.dev/blob/3a57b721e7df6fc52172f676ca68d16153bda6a3/.github/workflows/lint-workflow.yml#L26)
1414

1515
## Supported workflows
1616

@@ -19,6 +19,7 @@ don't allow this because they don't work on a level of individual jobs or steps.
1919
or **[pull_request_target](https://docs.github.com/en/actions/reference/events-that-trigger-workflows#pull_request_target)** event
2020
- Changes are detected against the pull request base branch
2121
- Uses GitHub REST API to fetch a list of modified files
22+
- Requires [pull-requests: read](https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs) permission
2223
- **Feature branches:**
2324
- Workflow triggered by **[push](https://docs.github.com/en/actions/reference/events-that-trigger-workflows#push)**
2425
or any other **[event](https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows)**
@@ -173,7 +174,7 @@ jobs:
173174
tests:
174175
runs-on: ubuntu-latest
175176
steps:
176-
- uses: actions/checkout@v2
177+
- uses: actions/checkout@v3
177178
- uses: dorny/paths-filter@v2
178179
id: filter
179180
with:
@@ -209,6 +210,9 @@ jobs:
209210
# JOB to run change detection
210211
changes:
211212
runs-on: ubuntu-latest
213+
# Required permissions
214+
permissions:
215+
pull-requests: read
212216
# Set job outputs to values from filter step
213217
outputs:
214218
backend: ${{ steps.filter.outputs.backend }}
@@ -230,7 +234,7 @@ jobs:
230234
if: ${{ needs.changes.outputs.backend == 'true' }}
231235
runs-on: ubuntu-latest
232236
steps:
233-
- uses: actions/checkout@v2
237+
- uses: actions/checkout@v3
234238
- ...
235239
236240
# JOB to build and test frontend code
@@ -239,7 +243,7 @@ jobs:
239243
if: ${{ needs.changes.outputs.frontend == 'true' }}
240244
runs-on: ubuntu-latest
241245
steps:
242-
- uses: actions/checkout@v2
246+
- uses: actions/checkout@v3
243247
- ...
244248
```
245249

@@ -253,6 +257,9 @@ jobs:
253257
# JOB to run change detection
254258
changes:
255259
runs-on: ubuntu-latest
260+
# Required permissions
261+
permissions:
262+
pull-requests: read
256263
outputs:
257264
# Expose matched filters as job 'packages' output variable
258265
packages: ${{ steps.filter.outputs.changes }}
@@ -275,7 +282,7 @@ jobs:
275282
package: ${{ fromJSON(needs.changes.outputs.packages) }}
276283
runs-on: ubuntu-latest
277284
steps:
278-
- uses: actions/checkout@v2
285+
- uses: actions/checkout@v3
279286
- ...
280287
```
281288

@@ -295,8 +302,11 @@ on:
295302
jobs:
296303
build:
297304
runs-on: ubuntu-latest
305+
# Required permissions
306+
permissions:
307+
pull-requests: read
298308
steps:
299-
- uses: actions/checkout@v2
309+
- uses: actions/checkout@v3
300310
- uses: dorny/paths-filter@v2
301311
id: filter
302312
with:
@@ -317,7 +327,7 @@ jobs:
317327
build:
318328
runs-on: ubuntu-latest
319329
steps:
320-
- uses: actions/checkout@v2
330+
- uses: actions/checkout@v3
321331
with:
322332
# This may save additional git fetch roundtrip if
323333
# merge-base is found within latest 20 commits
@@ -345,7 +355,7 @@ jobs:
345355
build:
346356
runs-on: ubuntu-latest
347357
steps:
348-
- uses: actions/checkout@v2
358+
- uses: actions/checkout@v3
349359
- uses: dorny/paths-filter@v2
350360
id: filter
351361
with:
@@ -373,7 +383,7 @@ jobs:
373383
build:
374384
runs-on: ubuntu-latest
375385
steps:
376-
- uses: actions/checkout@v2
386+
- uses: actions/checkout@v3
377387
378388
# Some action that modifies files tracked by git (e.g. code linter)
379389
- uses: johndoe/some-action@v1

action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ inputs:
3434
If needed it uses single or double quotes to wrap filename with unsafe characters.
3535
'escape'- Space delimited list usable as command line argument list in linux shell.
3636
Backslash escapes every potentially unsafe character.
37-
required: true
37+
required: false
3838
default: none
3939
initial-fetch-depth:
4040
description: |
@@ -48,7 +48,7 @@ outputs:
4848
changes:
4949
description: JSON array with names of all filters matching any of changed files
5050
runs:
51-
using: 'node12'
51+
using: 'node16'
5252
main: 'dist/index.js'
5353
branding:
5454
color: blue

0 commit comments

Comments
 (0)