Skip to content

Commit bf5c735

Browse files
authored
eslint check the .github/actions-scripts/* files too (github#23698)
* eslint check the .github/actions-scripts/* files too * but ignore node_modules/.bin/* * fix errors * last one * feedbacked
1 parent 0faa5ce commit bf5c735

File tree

6 files changed

+8
-5
lines changed

6 files changed

+8
-5
lines changed

.eslintrc.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ module.exports = {
1313
babelOptions: { configFile: './.babelrc' },
1414
sourceType: 'module',
1515
},
16-
ignorePatterns: ['tmp/*'],
16+
ignorePatterns: ['tmp/*', '!/.*', '/.next/'],
1717
rules: {
1818
'import/no-extraneous-dependencies': ['error', { packageDir: '.' }],
1919
},

.github/actions-scripts/fr-add-docs-reviewers-requests.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,8 @@ async function run() {
134134
// Exclude existing items going forward.
135135
// Until we have a way to check from a PR whether the PR is in a project,
136136
// this is how we (roughly) avoid overwriting PRs that are already on the board
137-
let newItemIDs = []
138-
let newItemAuthors = []
137+
const newItemIDs = []
138+
const newItemAuthors = []
139139
itemIDs.forEach((id, index) => {
140140
if (!existingItemIDs.includes(id)) {
141141
newItemIDs.push(id)

.github/actions-scripts/ready-for-docs-review.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,8 @@ async function run() {
8585
// - affected docs sets (not considering changes to data/assets)
8686
let numFiles = 0
8787
let numChanges = 0
88-
let features = new Set([])
89-
const files = data.item.files.nodes.forEach((node) => {
88+
const features = new Set([])
89+
data.item.files.nodes.forEach((node) => {
9090
numFiles += 1
9191
numChanges += node.additions
9292
numChanges += node.deletions

.github/workflows/code-lint.yml

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ on:
1818
- '**.yaml'
1919
- '**.yml'
2020
- '**.scss'
21+
- .eslintrc.js
2122
# In case something like eslint or tsc or prettier upgrades
2223
- 'package-lock.json'
2324
# Ultimately, for debugging this workflow itself

package-lock.json

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@
105105
"@graphql-inspector/core": "^2.9.0",
106106
"@graphql-tools/load": "^7.4.1",
107107
"@jest/globals": "^27.3.1",
108+
"@octokit/graphql": "4.8.0",
108109
"@octokit/rest": "^18.12.0",
109110
"@types/github-slugger": "^1.3.0",
110111
"@types/imurmurhash": "^0.1.1",

0 commit comments

Comments
 (0)