@adbayb/stack 2.30.0 → 2.32.0

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.
Files changed (30) hide show
  1. package/configs/eslint/constants.js +31 -6
  2. package/configs/eslint/helpers.js +2 -3
  3. package/configs/eslint/index.js +14 -17
  4. package/configs/eslint/presets/eslint.js +28 -8
  5. package/configs/eslint/presets/import.js +12 -4
  6. package/configs/eslint/presets/jsdoc.js +73 -74
  7. package/configs/eslint/presets/markdown.js +1 -3
  8. package/configs/eslint/presets/node.js +41 -43
  9. package/configs/eslint/presets/prettier.js +1 -0
  10. package/configs/eslint/presets/react.js +98 -61
  11. package/configs/eslint/presets/sonar.js +16 -6
  12. package/configs/eslint/presets/stylistic.js +72 -73
  13. package/configs/eslint/presets/test.js +56 -65
  14. package/configs/eslint/presets/typescript.js +6 -8
  15. package/configs/eslint/presets/uncategorized.js +37 -38
  16. package/configs/eslint/presets/unicorn.js +131 -129
  17. package/dist/index.js +9 -7
  18. package/package.json +21 -21
  19. package/templates/multi-projects/.github/workflows/continuous_delivery.yml +3 -7
  20. package/templates/multi-projects/.github/workflows/conventional_commit.yml +1 -1
  21. package/templates/multi-projects/.github/workflows/dependency_changelog.yml +2 -2
  22. package/templates/multi-projects/.github/workflows/workflow.yml +3 -7
  23. package/templates/multi-projects/package.json.tmpl +1 -1
  24. package/templates/single-project/.github/workflows/continuous_delivery.yml +3 -7
  25. package/templates/single-project/.github/workflows/conventional_commit.yml +1 -1
  26. package/templates/single-project/.github/workflows/dependency_changelog.yml +2 -2
  27. package/templates/single-project/.github/workflows/workflow.yml +3 -7
  28. package/templates/single-project/package.json.tmpl +1 -1
  29. package/configs/eslint/presets/base.js +0 -26
  30. package/configs/eslint/presets/overridable.js +0 -29
@@ -1,134 +1,136 @@
1
1
  import unicornPlugin from "eslint-plugin-unicorn";
2
2
 
3
- import { JAVASCRIPT_LIKE_EXTENSIONS } from "../constants.js";
3
+ import { createConfig } from "../helpers.js";
4
+ import { JAVASCRIPT_LIKE_FILES } from "../constants.js";
4
5
 
5
- export const config = [
6
- // TODO: Add new rules https://github.com/sindresorhus/eslint-plugin-unicorn/releases/tag/v60.0.0
7
- {
8
- files: JAVASCRIPT_LIKE_EXTENSIONS,
9
- plugins: {
10
- unicorn: unicornPlugin,
11
- },
12
- rules: {
13
- "unicorn/better-regex": "error",
14
- "unicorn/catch-error-name": [
15
- "error",
16
- {
17
- name: "error",
18
- },
19
- ],
20
- "unicorn/consistent-empty-array-spread": "error",
21
- "unicorn/consistent-existence-index-check": "error",
22
- "unicorn/consistent-function-scoping": "error",
23
- "unicorn/custom-error-definition": "error",
24
- "unicorn/error-message": "error",
25
- "unicorn/escape-case": "error",
26
- "unicorn/expiring-todo-comments": "error",
27
- "unicorn/explicit-length-check": "error",
28
- "unicorn/filename-case": [
29
- "error",
30
- {
31
- cases: {
32
- camelCase: true,
33
- pascalCase: true,
34
- },
35
- },
36
- ],
37
- "unicorn/new-for-builtins": "error",
38
- "unicorn/no-abusive-eslint-disable": "error",
39
- "unicorn/no-array-callback-reference": "error",
40
- "unicorn/no-array-reverse": "error",
41
- "unicorn/no-await-in-promise-methods": "error",
42
- "unicorn/no-console-spaces": "error",
43
- "unicorn/no-document-cookie": "error",
44
- "unicorn/no-empty-file": "error",
45
- "unicorn/no-for-loop": "error",
46
- "unicorn/no-instanceof-array": "error",
47
- "unicorn/no-invalid-fetch-options": "error",
48
- "unicorn/no-invalid-remove-event-listener": "error",
49
- "unicorn/no-new-buffer": "error",
50
- "unicorn/no-object-as-default-parameter": "error",
51
- "unicorn/no-process-exit": "error",
52
- "unicorn/no-single-promise-in-promise-methods": "error",
53
- "unicorn/no-static-only-class": "error",
54
- "unicorn/no-typeof-undefined": "error",
55
- "unicorn/no-unnecessary-array-flat-depth": "error",
56
- "unicorn/no-unnecessary-array-splice-count": "error",
57
- "unicorn/no-unnecessary-polyfills": "error",
58
- "unicorn/no-unnecessary-slice-end": "error",
59
- "unicorn/no-unreadable-array-destructuring": "error",
60
- "unicorn/no-unreadable-iife": "error",
61
- "unicorn/no-unused-properties": "error",
62
- "unicorn/no-useless-error-capture-stack-trace": "error",
63
- "unicorn/no-useless-fallback-in-spread": "error",
64
- "unicorn/no-useless-length-check": "error",
65
- "unicorn/no-useless-promise-resolve-reject": "error",
66
- "unicorn/no-useless-spread": "error",
67
- "unicorn/no-zero-fractions": "error",
68
- "unicorn/number-literal-case": "error",
69
- "unicorn/prefer-add-event-listener": "error",
70
- "unicorn/prefer-array-find": "error",
71
- "unicorn/prefer-array-flat": "error",
72
- "unicorn/prefer-array-flat-map": "error",
73
- "unicorn/prefer-array-index-of": "error",
74
- "unicorn/prefer-array-some": "error",
75
- "unicorn/prefer-blob-reading-methods": "error",
76
- "unicorn/prefer-class-fields": "error",
77
- "unicorn/prefer-code-point": "error",
78
- "unicorn/prefer-date-now": "error",
79
- "unicorn/prefer-dom-node-append": "error",
80
- "unicorn/prefer-dom-node-remove": "error",
81
- "unicorn/prefer-dom-node-text-content": "error",
82
- "unicorn/prefer-event-target": "error",
83
- "unicorn/prefer-export-from": [
84
- "error",
85
- { ignoreUsedVariables: true },
86
- ],
87
- "unicorn/prefer-global-this": "error",
88
- "unicorn/prefer-import-meta-properties": "error",
89
- "unicorn/prefer-includes": "error",
90
- "unicorn/prefer-keyboard-event-key": "error",
91
- "unicorn/prefer-logical-operator-over-ternary": "error",
92
- "unicorn/prefer-math-min-max": "error",
93
- "unicorn/prefer-math-trunc": "error",
94
- "unicorn/prefer-modern-dom-apis": "error",
95
- "unicorn/prefer-modern-math-apis": "error",
96
- "unicorn/prefer-module": "error",
97
- "unicorn/prefer-native-coercion-functions": "error",
98
- "unicorn/prefer-negative-index": "error",
99
- "unicorn/prefer-number-properties": "error",
100
- "unicorn/prefer-object-from-entries": "error",
101
- "unicorn/prefer-optional-catch-binding": "error",
102
- "unicorn/prefer-prototype-methods": "error",
103
- "unicorn/prefer-query-selector": "error",
104
- "unicorn/prefer-reflect-apply": "error",
105
- "unicorn/prefer-regexp-test": "error",
106
- "unicorn/prefer-set-has": "error",
107
- "unicorn/prefer-set-size": "error",
108
- "unicorn/prefer-single-call": "error",
109
- "unicorn/prefer-spread": "error",
110
- "unicorn/prefer-string-raw": "error",
111
- "unicorn/prefer-string-replace-all": "error",
112
- "unicorn/prefer-string-slice": "error",
113
- "unicorn/prefer-string-starts-ends-with": "error",
114
- "unicorn/prefer-string-trim-start-end": "error",
115
- "unicorn/prefer-structured-clone": "error",
116
- "unicorn/prefer-switch": "error",
117
- "unicorn/prefer-ternary": "error",
118
- "unicorn/prefer-top-level-await": "error",
119
- "unicorn/prefer-type-error": "error",
120
- "unicorn/prevent-abbreviations": [
121
- "error",
122
- {
123
- ignore: [/^props/i, /props$/i, /^ref/i, /ref$/i],
6
+ export const config = createConfig({
7
+ files: JAVASCRIPT_LIKE_FILES,
8
+ plugins: {
9
+ unicorn: unicornPlugin,
10
+ },
11
+ rules: {
12
+ "unicorn/better-regex": "error",
13
+ "unicorn/catch-error-name": [
14
+ "error",
15
+ {
16
+ name: "error",
17
+ },
18
+ ],
19
+ "unicorn/consistent-empty-array-spread": "error",
20
+ "unicorn/consistent-existence-index-check": "error",
21
+ "unicorn/consistent-function-scoping": "error",
22
+ "unicorn/custom-error-definition": "error",
23
+ "unicorn/error-message": "error",
24
+ "unicorn/escape-case": "error",
25
+ "unicorn/expiring-todo-comments": "error",
26
+ "unicorn/explicit-length-check": "error",
27
+ "unicorn/filename-case": [
28
+ "error",
29
+ {
30
+ cases: {
31
+ camelCase: true,
32
+ pascalCase: true,
124
33
  },
125
- ],
126
- "unicorn/relative-url-style": ["error", "always"],
127
- "unicorn/require-array-join-separator": "error",
128
- "unicorn/require-number-to-fixed-digits-argument": "error",
129
- "unicorn/switch-case-braces": "error",
130
- "unicorn/text-encoding-identifier-case": "error",
131
- "unicorn/throw-new-error": "error",
132
- },
34
+ },
35
+ ],
36
+ "unicorn/new-for-builtins": "error",
37
+ "unicorn/no-abusive-eslint-disable": "error",
38
+ "unicorn/no-array-callback-reference": "error",
39
+ "unicorn/no-array-reverse": "error",
40
+ "unicorn/no-array-sort": "error",
41
+ "unicorn/no-await-in-promise-methods": "error",
42
+ "unicorn/no-console-spaces": "error",
43
+ "unicorn/no-document-cookie": "error",
44
+ "unicorn/no-empty-file": "error",
45
+ "unicorn/no-for-loop": "error",
46
+ "unicorn/no-immediate-mutation": "error",
47
+ "unicorn/no-instanceof-array": "error",
48
+ "unicorn/no-invalid-fetch-options": "error",
49
+ "unicorn/no-invalid-remove-event-listener": "error",
50
+ "unicorn/no-new-buffer": "error",
51
+ "unicorn/no-object-as-default-parameter": "error",
52
+ "unicorn/no-process-exit": "error",
53
+ "unicorn/no-single-promise-in-promise-methods": "error",
54
+ "unicorn/no-static-only-class": "error",
55
+ "unicorn/no-typeof-undefined": "error",
56
+ "unicorn/no-unnecessary-array-flat-depth": "error",
57
+ "unicorn/no-unnecessary-array-splice-count": "error",
58
+ "unicorn/no-unnecessary-polyfills": "error",
59
+ "unicorn/no-unnecessary-slice-end": "error",
60
+ "unicorn/no-unreadable-array-destructuring": "error",
61
+ "unicorn/no-unreadable-iife": "error",
62
+ "unicorn/no-unused-properties": "error",
63
+ "unicorn/no-useless-collection-argument": "error",
64
+ "unicorn/no-useless-error-capture-stack-trace": "error",
65
+ "unicorn/no-useless-fallback-in-spread": "error",
66
+ "unicorn/no-useless-length-check": "error",
67
+ "unicorn/no-useless-promise-resolve-reject": "error",
68
+ "unicorn/no-useless-spread": "error",
69
+ "unicorn/no-zero-fractions": "error",
70
+ "unicorn/number-literal-case": "error",
71
+ "unicorn/prefer-add-event-listener": "error",
72
+ "unicorn/prefer-array-find": "error",
73
+ "unicorn/prefer-array-flat": "error",
74
+ "unicorn/prefer-array-flat-map": "error",
75
+ "unicorn/prefer-array-index-of": "error",
76
+ "unicorn/prefer-array-some": "error",
77
+ "unicorn/prefer-bigint-literals": "error",
78
+ "unicorn/prefer-blob-reading-methods": "error",
79
+ "unicorn/prefer-class-fields": "error",
80
+ "unicorn/prefer-classlist-toggle": "error",
81
+ "unicorn/prefer-code-point": "error",
82
+ "unicorn/prefer-date-now": "error",
83
+ "unicorn/prefer-dom-node-append": "error",
84
+ "unicorn/prefer-dom-node-remove": "error",
85
+ "unicorn/prefer-dom-node-text-content": "error",
86
+ "unicorn/prefer-event-target": "error",
87
+ "unicorn/prefer-export-from": ["error", { ignoreUsedVariables: true }],
88
+ "unicorn/prefer-global-this": "error",
89
+ "unicorn/prefer-import-meta-properties": "error",
90
+ "unicorn/prefer-includes": "error",
91
+ "unicorn/prefer-keyboard-event-key": "error",
92
+ "unicorn/prefer-logical-operator-over-ternary": "error",
93
+ "unicorn/prefer-math-min-max": "error",
94
+ "unicorn/prefer-math-trunc": "error",
95
+ "unicorn/prefer-modern-dom-apis": "error",
96
+ "unicorn/prefer-modern-math-apis": "error",
97
+ "unicorn/prefer-module": "error",
98
+ "unicorn/prefer-native-coercion-functions": "error",
99
+ "unicorn/prefer-negative-index": "error",
100
+ "unicorn/prefer-number-properties": "error",
101
+ "unicorn/prefer-object-from-entries": "error",
102
+ "unicorn/prefer-optional-catch-binding": "error",
103
+ "unicorn/prefer-prototype-methods": "error",
104
+ "unicorn/prefer-query-selector": "error",
105
+ "unicorn/prefer-reflect-apply": "error",
106
+ "unicorn/prefer-regexp-test": "error",
107
+ "unicorn/prefer-response-static-json": "error",
108
+ "unicorn/prefer-set-has": "error",
109
+ "unicorn/prefer-set-size": "error",
110
+ "unicorn/prefer-single-call": "error",
111
+ "unicorn/prefer-spread": "error",
112
+ "unicorn/prefer-string-raw": "error",
113
+ "unicorn/prefer-string-replace-all": "error",
114
+ "unicorn/prefer-string-slice": "error",
115
+ "unicorn/prefer-string-starts-ends-with": "error",
116
+ "unicorn/prefer-string-trim-start-end": "error",
117
+ "unicorn/prefer-structured-clone": "error",
118
+ "unicorn/prefer-switch": "error",
119
+ "unicorn/prefer-ternary": "error",
120
+ "unicorn/prefer-top-level-await": "error",
121
+ "unicorn/prefer-type-error": "error",
122
+ "unicorn/prevent-abbreviations": [
123
+ "error",
124
+ {
125
+ ignore: [/^props/i, /props$/i, /^ref/i, /ref$/i],
126
+ },
127
+ ],
128
+ "unicorn/relative-url-style": ["error", "always"],
129
+ "unicorn/require-array-join-separator": "error",
130
+ "unicorn/require-module-attributes": "error",
131
+ "unicorn/require-number-to-fixed-digits-argument": "error",
132
+ "unicorn/switch-case-braces": "error",
133
+ "unicorn/text-encoding-identifier-case": "error",
134
+ "unicorn/throw-new-error": "error",
133
135
  },
134
- ];
136
+ });
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@ import { writeFile, chmod, mkdir, symlink, rm } from 'node:fs/promises';
5
5
  import { existsSync, cpSync, readFileSync, renameSync, writeFileSync, readdirSync } from 'node:fs';
6
6
  import { fdir } from 'fdir';
7
7
 
8
- const require = createRequire(import.meta.url);
8
+ const require$1 = createRequire(import.meta.url);
9
9
  function assert(expectedCondition, createError) {
10
10
  if (!expectedCondition) {
11
11
  throw createError();
@@ -100,7 +100,7 @@ const getStackCommand = (command, isNodeRuntime = true)=>{
100
100
  ].join(" ");
101
101
  };
102
102
  const hasDependency = (packageName)=>{
103
- return Boolean(require.resolve(packageName));
103
+ return Boolean(require$1.resolve(packageName));
104
104
  };
105
105
  const setPackageManager = async ()=>{
106
106
  /**
@@ -131,9 +131,11 @@ const eslint = (options)=>async (files = [])=>{
131
131
  if (eslintFiles.length === 0) return;
132
132
  }
133
133
  const arguments_ = [
134
- ...eslintFiles
134
+ ...eslintFiles,
135
+ "--cache",
136
+ `--cache-location ${resolveFromProjectDirectory("node_modules/.cache/.eslintcache")}`,
137
+ "--no-error-on-unmatched-pattern"
135
138
  ];
136
- arguments_.push("--cache", `--cache-location ${resolveFromProjectDirectory("node_modules/.cache/.eslintcache")}`, "--no-error-on-unmatched-pattern");
137
139
  if (options.isFixMode) {
138
140
  arguments_.push("--fix");
139
141
  }
@@ -195,7 +197,7 @@ const ESLINT_EXTENSIONS = [
195
197
  "mdx"
196
198
  ];
197
199
 
198
- var version = "2.30.0";
200
+ var version = "2.32.0";
199
201
 
200
202
  const createWatchCommand = (program)=>{
201
203
  program.command({
@@ -523,7 +525,7 @@ const label$2 = (message)=>`${message} 🔨`;
523
525
  /** Template folder mutations. */ new fdir().withBasePath().onlyDirs().filter((path)=>{
524
526
  return templateExpressionRegExp.test(path);
525
527
  }).crawl(projectRootPath).sync()// Re-order from longest to lowest path length to apply first renaming operations on deepest file structure
526
- .sort((a, b)=>b.length - a.length).forEach((templateFolderPath)=>{
528
+ .toSorted((a, b)=>b.length - a.length).forEach((templateFolderPath)=>{
527
529
  const newPath = templateFolderPath.replaceAll(templateExpressionRegExp, (_, dataModelKey)=>{
528
530
  return dataModel[dataModelKey];
529
531
  });
@@ -602,7 +604,7 @@ const checkDependency = async ()=>{
602
604
  const packages = JSON.parse(stdout).map((package_)=>{
603
605
  const packagePath = join(package_.path, "package.json");
604
606
  assert(package_.name, ()=>createPackageError(`\`${packagePath}\` must have a name field.`));
605
- const packageContent = require(packagePath);
607
+ const packageContent = require$1(packagePath);
606
608
  const peerDependencies = packageContent.peerDependencies ?? {};
607
609
  const devDependencies = packageContent.devDependencies ?? {};
608
610
  const dependencies = packageContent.dependencies ?? {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adbayb/stack",
3
- "version": "2.30.0",
3
+ "version": "2.32.0",
4
4
  "description": "My opinionated JavaScript-based toolchain",
5
5
  "keywords": [
6
6
  "stack",
@@ -40,39 +40,39 @@
40
40
  ],
41
41
  "dependencies": {
42
42
  "@changesets/changelog-github": "^0.5.1",
43
- "@changesets/cli": "^2.29.6",
44
- "@commitlint/cli": "^19.8.1",
45
- "@commitlint/config-conventional": "^19.8.1",
46
- "@eslint-react/eslint-plugin": "^1.52.6",
47
- "@eslint/compat": "^1.3.2",
48
- "@stylistic/eslint-plugin": "^5.2.3",
49
- "@vitest/eslint-plugin": "^1.3.3",
50
- "eslint": "^9.34.0",
43
+ "@changesets/cli": "^2.29.7",
44
+ "@commitlint/cli": "^20.1.0",
45
+ "@commitlint/config-conventional": "^20.0.0",
46
+ "@eslint-react/eslint-plugin": "^2.3.5",
47
+ "@eslint/compat": "^2.0.0",
48
+ "@stylistic/eslint-plugin": "^5.6.1",
49
+ "@vitest/eslint-plugin": "^1.4.3",
50
+ "eslint": "^9.39.1",
51
51
  "eslint-config-prettier": "^10.1.8",
52
52
  "eslint-import-resolver-typescript": "^4.4.4",
53
- "eslint-plugin-depend": "^1.2.0",
53
+ "eslint-plugin-depend": "^1.4.0",
54
54
  "eslint-plugin-import-x": "^4.16.1",
55
55
  "eslint-plugin-jest-formatting": "^3.1.0",
56
- "eslint-plugin-jsdoc": "^54.1.1",
56
+ "eslint-plugin-jsdoc": "^61.3.0",
57
57
  "eslint-plugin-mdx": "^3.6.2",
58
- "eslint-plugin-n": "^17.21.3",
58
+ "eslint-plugin-n": "^17.23.1",
59
59
  "eslint-plugin-prettier": "^5.5.4",
60
- "eslint-plugin-react-hooks": "^5.2.0",
61
- "eslint-plugin-sonarjs": "^3.0.4",
60
+ "eslint-plugin-react-hooks": "^7.0.1",
61
+ "eslint-plugin-sonarjs": "^3.0.5",
62
62
  "eslint-plugin-sort-keys-custom-order": "^2.2.1",
63
- "eslint-plugin-unicorn": "^60.0.0",
63
+ "eslint-plugin-unicorn": "^62.0.0",
64
64
  "fdir": "^6.5.0",
65
- "globals": "^16.3.0",
65
+ "globals": "^16.5.0",
66
66
  "prettier": "^3.6.2",
67
67
  "prettier-plugin-packagejson": "^2.5.19",
68
68
  "termost": "^1.8.0",
69
- "turbo": "^2.5.6",
70
- "typescript": "^5.9.2",
71
- "typescript-eslint": "^8.40.0"
69
+ "turbo": "^2.6.1",
70
+ "typescript": "^5.9.3",
71
+ "typescript-eslint": "^8.47.0"
72
72
  },
73
73
  "devDependencies": {
74
- "@types/node": "22.17.2",
75
- "quickbundle": "2.13.0"
74
+ "@types/node": "24.10.1",
75
+ "quickbundle": "2.15.0"
76
76
  },
77
77
  "publishConfig": {
78
78
  "access": "public",
@@ -18,15 +18,11 @@ jobs:
18
18
  contents: write
19
19
  pull-requests: write
20
20
  steps:
21
- - uses: actions/checkout@v4
21
+ - uses: actions/checkout@v5
22
22
  - uses: pnpm/action-setup@v4
23
- - name: Get node version
24
- run: echo "version=$(cat .nvmrc)" >> $GITHUB_OUTPUT
25
- id: node
26
- - name: Setup node ${{ steps.node.outputs.version }}
27
- uses: actions/setup-node@v4
23
+ - uses: actions/setup-node@v6
28
24
  with:
29
- node-version: ${{ steps.node.outputs.version }}
25
+ node-version-file: ".nvmrc"
30
26
  cache: pnpm
31
27
  - name: Setup .npmrc
32
28
  run: |
@@ -9,7 +9,7 @@ jobs:
9
9
  timeout-minutes: 5
10
10
  runs-on: ubuntu-latest
11
11
  steps:
12
- - uses: amannn/action-semantic-pull-request@v5
12
+ - uses: amannn/action-semantic-pull-request@v6
13
13
  id: check_pr_rule
14
14
  env:
15
15
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -12,7 +12,7 @@ jobs:
12
12
  if: github.actor == 'renovate[bot]'
13
13
  steps:
14
14
  - name: Checkout
15
- uses: actions/checkout@v4
15
+ uses: actions/checkout@v5
16
16
  with:
17
17
  fetch-depth: 2
18
18
  ref: ${{ github.head_ref }}
@@ -21,7 +21,7 @@ jobs:
21
21
  git config --global user.email adbayb@gmail.com
22
22
  git config --global user.name 'Ayoub Adib'
23
23
  - name: Create changelog entry
24
- uses: actions/github-script@v7
24
+ uses: actions/github-script@v8
25
25
  # Credits to https://github.com/backstage/backstage/blob/bcc11651add5a2589898dfb9d665ebb9d412201b/.github/workflows/sync_renovate-changesets.yml
26
26
  with:
27
27
  script: |
@@ -9,15 +9,11 @@ jobs:
9
9
  runs-on: ubuntu-latest
10
10
  steps:
11
11
  - name: Checkout the code
12
- uses: actions/checkout@v4
12
+ uses: actions/checkout@v5
13
13
  - uses: pnpm/action-setup@v4
14
- - name: Get node version
15
- run: echo "version=$(cat .nvmrc)" >> $GITHUB_OUTPUT
16
- id: node
17
- - name: Setup node ${{ steps.node.outputs.version }}
18
- uses: actions/setup-node@v4
14
+ - uses: actions/setup-node@v6
19
15
  with:
20
- node-version: ${{ steps.node.outputs.version }}
16
+ node-version-file: ".nvmrc"
21
17
  cache: pnpm
22
18
  - name: Setup cache
23
19
  id: cache
@@ -19,7 +19,7 @@
19
19
  "prettier": "@adbayb/stack/prettier",
20
20
  "packageManager": "pnpm@{{npmVersion}}",
21
21
  "engines": {
22
- "node": ">=22.0.0",
22
+ "node": ">=24.0.0",
23
23
  "pnpm": ">=10.0.0"
24
24
  }
25
25
  }
@@ -18,15 +18,11 @@ jobs:
18
18
  contents: write
19
19
  pull-requests: write
20
20
  steps:
21
- - uses: actions/checkout@v4
21
+ - uses: actions/checkout@v5
22
22
  - uses: pnpm/action-setup@v4
23
- - name: Get node version
24
- run: echo "version=$(cat .nvmrc)" >> $GITHUB_OUTPUT
25
- id: node
26
- - name: Setup node ${{ steps.node.outputs.version }}
27
- uses: actions/setup-node@v4
23
+ - uses: actions/setup-node@v6
28
24
  with:
29
- node-version: ${{ steps.node.outputs.version }}
25
+ node-version-file: ".nvmrc"
30
26
  cache: pnpm
31
27
  - name: Setup .npmrc
32
28
  run: |
@@ -9,7 +9,7 @@ jobs:
9
9
  timeout-minutes: 5
10
10
  runs-on: ubuntu-latest
11
11
  steps:
12
- - uses: amannn/action-semantic-pull-request@v5
12
+ - uses: amannn/action-semantic-pull-request@v6
13
13
  id: check_pr_rule
14
14
  env:
15
15
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -12,7 +12,7 @@ jobs:
12
12
  if: github.actor == 'renovate[bot]'
13
13
  steps:
14
14
  - name: Checkout
15
- uses: actions/checkout@v4
15
+ uses: actions/checkout@v5
16
16
  with:
17
17
  fetch-depth: 2
18
18
  ref: ${{ github.head_ref }}
@@ -21,7 +21,7 @@ jobs:
21
21
  git config --global user.email adbayb@gmail.com
22
22
  git config --global user.name 'Ayoub Adib'
23
23
  - name: Create changelog entry
24
- uses: actions/github-script@v7
24
+ uses: actions/github-script@v8
25
25
  # Credits to https://github.com/backstage/backstage/blob/bcc11651add5a2589898dfb9d665ebb9d412201b/.github/workflows/sync_renovate-changesets.yml
26
26
  with:
27
27
  script: |
@@ -9,15 +9,11 @@ jobs:
9
9
  runs-on: ubuntu-latest
10
10
  steps:
11
11
  - name: Checkout the code
12
- uses: actions/checkout@v4
12
+ uses: actions/checkout@v5
13
13
  - uses: pnpm/action-setup@v4
14
- - name: Get node version
15
- run: echo "version=$(cat .nvmrc)" >> $GITHUB_OUTPUT
16
- id: node
17
- - name: Setup node ${{ steps.node.outputs.version }}
18
- uses: actions/setup-node@v4
14
+ - uses: actions/setup-node@v6
19
15
  with:
20
- node-version: ${{ steps.node.outputs.version }}
16
+ node-version-file: ".nvmrc"
21
17
  cache: pnpm
22
18
  - name: Setup cache
23
19
  id: cache
@@ -19,7 +19,7 @@
19
19
  "prettier": "@adbayb/stack/prettier",
20
20
  "packageManager": "pnpm@{{npmVersion}}",
21
21
  "engines": {
22
- "node": ">=22.0.0",
22
+ "node": ">=24.0.0",
23
23
  "pnpm": ">=10.0.0"
24
24
  }
25
25
  }
@@ -1,26 +0,0 @@
1
- import { resolve } from "node:path";
2
-
3
- import globals from "globals";
4
- import { includeIgnoreFile } from "@eslint/compat";
5
-
6
- import { CWD } from "../constants.js";
7
-
8
- export const config = [
9
- {
10
- languageOptions: {
11
- ecmaVersion: "latest",
12
- globals: {
13
- ...globals.browser,
14
- ...globals.node,
15
- ...globals.worker,
16
- },
17
- parserOptions: {
18
- ecmaFeatures: {
19
- jsx: true,
20
- },
21
- },
22
- sourceType: "module",
23
- },
24
- },
25
- includeIgnoreFile(resolve(CWD, ".gitignore")),
26
- ];
@@ -1,29 +0,0 @@
1
- import eslintPluginPrettierRecommended from "eslint-plugin-prettier/recommended";
2
-
3
- export const config = [
4
- {
5
- // Relaxed rules for example-like folder, and [config-, story-, and test]-like files
6
- files: [
7
- "**/.config/**",
8
- "**/.configs/**",
9
- "**/config/**",
10
- "**/configs/**",
11
- "**/examples/**",
12
- "**/scripts/**",
13
- "**/website/**",
14
- "**/config.{js,ts,cjs,cts,mjs,mts}",
15
- "**/*.config.{js,ts,cjs,cts,mjs,mts}",
16
- "**/stories.{js,ts,jsx,tsx,cjs,cts,mjs,mts}",
17
- "**/*.stories.{js,ts,jsx,tsx,cjs,cts,mjs,mts}",
18
- "**/test.{js,ts,jsx,tsx,cjs,cts,mjs,mts}",
19
- "**/*.test.{js,ts,jsx,tsx,cjs,cts,mjs,mts}",
20
- ],
21
- rules: {
22
- "import-x/no-anonymous-default-export": "off",
23
- "import-x/no-default-export": "off",
24
- "sonarjs/file-name-differ-from-class": "off",
25
- "sonarjs/sonar-no-magic-numbers": "off",
26
- },
27
- },
28
- eslintPluginPrettierRecommended,
29
- ];