@darksheep/eslint 4.1.5 โ†’ 4.1.7

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/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # Changelog
2
2
 
3
+ ## [4.1.7](https://github.com/DarkSheepSoftware/eslint/compare/v4.1.6...v4.1.7) (2024-03-02)
4
+
5
+
6
+ ### ๐Ÿ“ฆ Dependencies
7
+
8
+ * **dev:** update dependency @types/node to v20.11.24 ([#273](https://github.com/DarkSheepSoftware/eslint/issues/273)) ([ccdd44b](https://github.com/DarkSheepSoftware/eslint/commit/ccdd44bdd2052234001fbdacc6053e03048182da))
9
+
10
+
11
+ ### ๐Ÿงน Chores
12
+
13
+ * allow sync in test files ([#275](https://github.com/DarkSheepSoftware/eslint/issues/275)) ([7334c77](https://github.com/DarkSheepSoftware/eslint/commit/7334c770d7b316975e476f443a07cc135ab13df6))
14
+
15
+ ## [4.1.6](https://github.com/DarkSheepSoftware/eslint/compare/v4.1.5...v4.1.6) (2024-02-29)
16
+
17
+
18
+ ### ๐Ÿ“ฆ Dependencies
19
+
20
+ * **dev:** update dependency @types/eslint to v8.56.5 ([#256](https://github.com/DarkSheepSoftware/eslint/issues/256)) ([c003b0c](https://github.com/DarkSheepSoftware/eslint/commit/c003b0cdde7184902e54b44f7550bf52b8d3ea3f))
21
+ * **dev:** update dependency @types/node to v20.11.22 ([#257](https://github.com/DarkSheepSoftware/eslint/issues/257)) ([66fc7b1](https://github.com/DarkSheepSoftware/eslint/commit/66fc7b136d4e2f211b4339d47f3e67de4f8761ff))
22
+ * **dev:** update dependency @types/node to v20.11.23 ([#272](https://github.com/DarkSheepSoftware/eslint/issues/272)) ([0c442e5](https://github.com/DarkSheepSoftware/eslint/commit/0c442e53269ac907e60914e3d49a9a927955808d))
23
+ * **lock:** lock file maintenance ([#270](https://github.com/DarkSheepSoftware/eslint/issues/270)) ([d456726](https://github.com/DarkSheepSoftware/eslint/commit/d456726eff6ce461273d5bf22151c52e0682cb9b))
24
+ * **pkg:** update dependency @stylistic/eslint-plugin to v1.6.3 ([#260](https://github.com/DarkSheepSoftware/eslint/issues/260)) ([3c2b223](https://github.com/DarkSheepSoftware/eslint/commit/3c2b223e2024335d982e85b8a454455b120f84d9))
25
+
3
26
  ## [4.1.5](https://github.com/DarkSheepSoftware/eslint/compare/v4.1.4...v4.1.5) (2024-02-28)
4
27
 
5
28
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@darksheep/eslint",
3
- "version": "4.1.5",
3
+ "version": "4.1.7",
4
4
  "type": "module",
5
5
  "packageManager": "yarn@4.1.0",
6
6
  "bin": "./src/bin/eslint.cjs",
@@ -115,7 +115,7 @@ export async function createEslintImportConfig(root) {
115
115
  rules: rules,
116
116
  },
117
117
  {
118
- files: await getTypescriptFiles(),
118
+ files: getTypescriptFiles(),
119
119
  plugins: { import: importPlugin },
120
120
  languageOptions: {
121
121
  parserOptions: {
@@ -53,7 +53,7 @@ export async function createEslintJSDocConfig(root) {
53
53
  },
54
54
  },
55
55
  {
56
- files: await getTypescriptFiles(),
56
+ files: getTypescriptFiles(),
57
57
  rules: {
58
58
  'jsdoc/no-types': 'warn',
59
59
  'jsdoc/check-types': 'off',
@@ -7,6 +7,7 @@ import {
7
7
  getModuleFiles,
8
8
  getTypescriptFiles,
9
9
  getExampleFiles,
10
+ getTestFiles,
10
11
  } from '../utilities/eslint-files.js';
11
12
 
12
13
  const script = n.configs['flat/recommended-script'];
@@ -69,8 +70,8 @@ function toExt(globs) {
69
70
  export async function createEslintNodeConfigs(root) {
70
71
  const commonFiles = await getCommonFiles(root);
71
72
  const moduleFiles = await getModuleFiles(root);
72
- const typescriptFiles = await getTypescriptFiles();
73
- const exampleFiles = await getExampleFiles();
73
+ const typescriptFiles = getTypescriptFiles();
74
+ const exampleFiles = getExampleFiles();
74
75
  const rootDirectory = dirname(fileURLToPath(root));
75
76
 
76
77
  return [
@@ -125,5 +126,10 @@ export async function createEslintNodeConfigs(root) {
125
126
  'n/no-unsupported-features/es-syntax': [ 'error', { ignores: [ 'modules' ] } ],
126
127
  },
127
128
  },
129
+ {
130
+ files: getTestFiles(),
131
+ plugins: { n },
132
+ rules: { 'n/no-sync': 'off' },
133
+ },
128
134
  ];
129
135
  }
@@ -31,7 +31,7 @@ export async function createEslintSCAConfig(root) {
31
31
  },
32
32
  },
33
33
  {
34
- files: await getTypescriptFiles(),
34
+ files: getTypescriptFiles(),
35
35
  plugins: { sca },
36
36
  rules: {
37
37
  'sca/sequence-expression': 'error',
@@ -27,7 +27,7 @@ export async function createEslintTypescriptConfig(root) {
27
27
  const typescriptPlugin = idef(await import('@typescript-eslint/eslint-plugin'));
28
28
 
29
29
  return [ {
30
- files: await getTypescriptFiles(),
30
+ files: getTypescriptFiles(),
31
31
  languageOptions: {
32
32
  parser: /** @type {*} */ (typescriptParser),
33
33
  sourceType: 'module',
@@ -31,7 +31,7 @@ export async function createEslintUnusedImportsConfig(root) {
31
31
  },
32
32
  },
33
33
  {
34
- files: await getTypescriptFiles(),
34
+ files: getTypescriptFiles(),
35
35
  plugins: { 'unused-imports': unused },
36
36
  rules: {
37
37
  'no-unused-vars': 'off',
@@ -46,17 +46,30 @@ export async function getModuleFiles(root) {
46
46
 
47
47
  /**
48
48
  * Get a list of globs for typescript files
49
- * @returns {Promise<string[]>}
49
+ * @returns {string[]}
50
50
  */
51
- export async function getTypescriptFiles() {
51
+ export function getTypescriptFiles() {
52
52
  return [ '**/*.ts', '**/*.tsx' ];
53
53
  }
54
54
 
55
55
  /**
56
56
  * Get a list of possible example files
57
- * @returns {Promise<string[]>}
57
+ * @returns {string[]}
58
+ */
59
+ export function getTestFiles() {
60
+ return [
61
+ ...expandGlob('**/test.*'),
62
+ ...expandGlob('**/*.test.*'),
63
+ ...expandGlob('**/{test,tests}/*'),
64
+ ...expandGlob('**/{test,tests}/**/*'),
65
+ ];
66
+ }
67
+
68
+ /**
69
+ * Get a list of possible example files
70
+ * @returns {string[]}
58
71
  */
59
- export async function getExampleFiles() {
72
+ export function getExampleFiles() {
60
73
  return [
61
74
  ...expandGlob('**/example.{ts,js,tsx,jsx,mts,cts,mjs,cjs}'),
62
75
  ...expandGlob('**/{example,examples}/*'),