@gspothq/cli 0.0.0-stage → 0.1.1

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 (232) hide show
  1. package/README.md +18 -2
  2. package/configurations/database/postgres/manifest.toml +114 -0
  3. package/configurations/database/postgres/rules/POSTGRES.md +78 -0
  4. package/configurations/framework/astro/eslint-presets.json +138 -0
  5. package/configurations/framework/astro/manifest.toml +95 -0
  6. package/configurations/framework/astro/rules/ASTRO.md +39 -0
  7. package/configurations/framework/expo/manifest.toml +43 -0
  8. package/configurations/framework/express/manifest.toml +17 -0
  9. package/configurations/framework/express/rules/EXPRESS.md +73 -0
  10. package/configurations/framework/express/semgrep/express.yml +71 -0
  11. package/configurations/framework/fastapi/manifest.toml +11 -0
  12. package/configurations/framework/fastapi/rules/FASTAPI.md +100 -0
  13. package/configurations/framework/fastapi/semgrep/fastapi.yml +44 -0
  14. package/configurations/framework/nestjs/eslint-presets.json +62 -0
  15. package/configurations/framework/nestjs/manifest.toml +52 -0
  16. package/configurations/framework/nestjs/rules/NESTJS.md +44 -0
  17. package/configurations/framework/nextjs/eslint-presets.json +73 -0
  18. package/configurations/framework/nextjs/manifest.toml +119 -0
  19. package/configurations/framework/nextjs/rules/NEXTJS.md +43 -0
  20. package/configurations/framework/react/eslint-presets.json +77 -0
  21. package/configurations/framework/react/manifest.toml +93 -0
  22. package/configurations/framework/react/rules/REACT.md +108 -0
  23. package/configurations/framework/react-dom/eslint-presets.json +110 -0
  24. package/configurations/framework/react-dom/manifest.toml +24 -0
  25. package/configurations/framework/react-native/manifest.toml +46 -0
  26. package/configurations/framework/react-native/rules/REACT-NATIVE.md +51 -0
  27. package/configurations/framework/site/manifest.toml +170 -0
  28. package/configurations/framework/site/rules/SITE.md +20 -0
  29. package/configurations/framework/svelte/eslint-presets.json +67 -0
  30. package/configurations/framework/svelte/manifest.toml +83 -0
  31. package/configurations/framework/svelte/rules/SVELTE.md +48 -0
  32. package/configurations/framework/vue/eslint-presets.json +180 -0
  33. package/configurations/framework/vue/manifest.toml +83 -0
  34. package/configurations/framework/vue/rules/VUE.md +41 -0
  35. package/configurations/general/commits/manifest.toml +111 -0
  36. package/configurations/general/commits/rules/GIT.md +31 -0
  37. package/configurations/general/coverage/manifest.toml +3 -0
  38. package/configurations/general/dependencies/manifest.toml +159 -0
  39. package/configurations/general/dependencies/rules/DEPENDENCIES.md +30 -0
  40. package/configurations/general/dependencies/syncpack.json +15 -0
  41. package/configurations/general/docs/manifest.toml +79 -0
  42. package/configurations/general/docs/rules/DOCS.md +86 -0
  43. package/configurations/general/duplication/manifest.toml +32 -0
  44. package/configurations/general/engineering/manifest.toml +8 -0
  45. package/configurations/general/engineering/rules/agent/PLANNING.md +42 -0
  46. package/configurations/general/engineering/rules/agent/SUPPRESSIONS.md +16 -0
  47. package/configurations/general/engineering/rules/agent/TALKING.md +3 -0
  48. package/configurations/general/engineering/rules/agent/TASKS.md +19 -0
  49. package/configurations/general/engineering/rules/agent/WORKING.md +83 -0
  50. package/configurations/general/engineering/rules/code/ACCESSIBILITY.md +32 -0
  51. package/configurations/general/engineering/rules/code/CLI.md +37 -0
  52. package/configurations/general/engineering/rules/code/COMMENTS.md +38 -0
  53. package/configurations/general/engineering/rules/code/CONFIGURATION.md +25 -0
  54. package/configurations/general/engineering/rules/code/ERRORS.md +49 -0
  55. package/configurations/general/engineering/rules/code/HTTP.md +46 -0
  56. package/configurations/general/engineering/rules/code/LOGGING.md +55 -0
  57. package/configurations/general/engineering/rules/code/TESTING.md +58 -0
  58. package/configurations/general/files/manifest.toml +141 -0
  59. package/configurations/general/files/rules/YAML.md +19 -0
  60. package/configurations/general/format/manifest.toml +152 -0
  61. package/configurations/general/gspot/manifest.toml +65 -0
  62. package/configurations/general/gspot/rules/GENERATED.md +10 -0
  63. package/configurations/general/licenses/manifest.toml +33 -0
  64. package/configurations/general/naming/defaults.json +423 -0
  65. package/configurations/general/naming/manifest.toml +35 -0
  66. package/configurations/general/naming/rules/NAMING.md +179 -0
  67. package/configurations/general/prose/manifest.toml +86 -0
  68. package/configurations/general/prose/rules/WRITING.md +31 -0
  69. package/configurations/general/prose/vale/styles/LICENSES.md +55 -0
  70. package/configurations/general/prose/vale/styles/gspot/ampm.yml +8 -0
  71. package/configurations/general/prose/vale/styles/gspot/conscious-language.yml +16 -0
  72. package/configurations/general/prose/vale/styles/gspot/contractions.yml +43 -0
  73. package/configurations/general/prose/vale/styles/gspot/currency.yml +8 -0
  74. package/configurations/general/prose/vale/styles/gspot/dashes.yml +8 -0
  75. package/configurations/general/prose/vale/styles/gspot/date-ordinals.yml +41 -0
  76. package/configurations/general/prose/vale/styles/gspot/dates.yml +7 -0
  77. package/configurations/general/prose/vale/styles/gspot/file-paths.yml +7 -0
  78. package/configurations/general/prose/vale/styles/gspot/future.yml +17 -0
  79. package/configurations/general/prose/vale/styles/gspot/hedging.yml +22 -0
  80. package/configurations/general/prose/vale/styles/gspot/history.yml +16 -0
  81. package/configurations/general/prose/vale/styles/gspot/idioms.yml +21 -0
  82. package/configurations/general/prose/vale/styles/gspot/interface-verbs.yml +11 -0
  83. package/configurations/general/prose/vale/styles/gspot/jargon.yml +11 -0
  84. package/configurations/general/prose/vale/styles/gspot/leading-conjunctions.yml +12 -0
  85. package/configurations/general/prose/vale/styles/gspot/link-text.yml +8 -0
  86. package/configurations/general/prose/vale/styles/gspot/locations.yml +14 -0
  87. package/configurations/general/prose/vale/styles/gspot/marketing.yml +26 -0
  88. package/configurations/general/prose/vale/styles/gspot/merge-conflict-markers.yml +13 -0
  89. package/configurations/general/prose/vale/styles/gspot/militaristic-language.yml +22 -0
  90. package/configurations/general/prose/vale/styles/gspot/modals.yml +9 -0
  91. package/configurations/general/prose/vale/styles/gspot/numbered-units.yml +18 -0
  92. package/configurations/general/prose/vale/styles/gspot/obvious-fields.yml +14 -0
  93. package/configurations/general/prose/vale/styles/gspot/ordinal-adverbs.yml +15 -0
  94. package/configurations/general/prose/vale/styles/gspot/percentage-numbers.yml +8 -0
  95. package/configurations/general/prose/vale/styles/gspot/placeholders.yml +7 -0
  96. package/configurations/general/prose/vale/styles/gspot/product-centric-writing.yml +8 -0
  97. package/configurations/general/prose/vale/styles/gspot/punctuated-headings.yml +11 -0
  98. package/configurations/general/prose/vale/styles/gspot/self-reference.yml +15 -0
  99. package/configurations/general/prose/vale/styles/gspot/session-identifiers.yml +11 -0
  100. package/configurations/general/prose/vale/styles/gspot/since.yml +6 -0
  101. package/configurations/general/prose/vale/styles/gspot/straight-quotes.yml +11 -0
  102. package/configurations/general/prose/vale/styles/gspot/suspended-hyphens.yml +8 -0
  103. package/configurations/general/prose/vale/styles/gspot/symbols.yml +8 -0
  104. package/configurations/general/prose/vale/styles/gspot/time-ranges.yml +14 -0
  105. package/configurations/general/prose/vale/styles/gspot/url-prepositions.yml +10 -0
  106. package/configurations/general/prose/vale/styles/gspot/version-range.yml +8 -0
  107. package/configurations/general/repository/manifest.toml +24 -0
  108. package/configurations/general/secrets/gitleaks.toml +2 -0
  109. package/configurations/general/secrets/manifest.toml +125 -0
  110. package/configurations/general/secrets/rules/SECRETS.md +13 -0
  111. package/configurations/general/security/manifest.toml +77 -0
  112. package/configurations/general/security/rules/SECURITY.md +55 -0
  113. package/configurations/general/spelling/manifest.toml +46 -0
  114. package/configurations/general/structure/manifest.toml +70 -0
  115. package/configurations/infrastructure/ansible/manifest.toml +33 -0
  116. package/configurations/infrastructure/docker/manifest.toml +127 -0
  117. package/configurations/infrastructure/docker/rules/DOCKER.md +135 -0
  118. package/configurations/infrastructure/docker/trivyignore +2 -0
  119. package/configurations/infrastructure/github-actions/manifest.toml +76 -0
  120. package/configurations/infrastructure/github-actions/rules/GITHUB-ACTIONS.md +43 -0
  121. package/configurations/infrastructure/github-actions/zizmor.yml +3 -0
  122. package/configurations/infrastructure/nginx/manifest.toml +51 -0
  123. package/configurations/infrastructure/nginx/rules/NGINX.md +38 -0
  124. package/configurations/infrastructure/openapi/manifest.toml +50 -0
  125. package/configurations/infrastructure/openapi/rules/OPENAPI.md +39 -0
  126. package/configurations/infrastructure/xcode/manifest.toml +131 -0
  127. package/configurations/infrastructure/xcode/rules/XCODE.md +34 -0
  128. package/configurations/language/bash/manifest.toml +261 -0
  129. package/configurations/language/bash/rules/BASH.md +106 -0
  130. package/configurations/language/bash/rules/LANGUAGE.md +213 -0
  131. package/configurations/language/bash/rules/NAMING.md +62 -0
  132. package/configurations/language/bash/rules/OPERATIONS.md +77 -0
  133. package/configurations/language/bash/rules/SAFETY.md +222 -0
  134. package/configurations/language/bash/semgrep/bash.yml +30 -0
  135. package/configurations/language/css/manifest.toml +98 -0
  136. package/configurations/language/css/rules/CSS.md +28 -0
  137. package/configurations/language/css/rules/NAMING.md +17 -0
  138. package/configurations/language/css/rules/TAILWIND.md +26 -0
  139. package/configurations/language/css/stylelint-rule-names.json +89 -0
  140. package/configurations/language/html/manifest.toml +59 -0
  141. package/configurations/language/html/rules/HTML.md +27 -0
  142. package/configurations/language/html/rules/NAMING.md +16 -0
  143. package/configurations/language/javascript/eslint-presets.json +997 -0
  144. package/configurations/language/javascript/eslint-rule-names.json +299 -0
  145. package/configurations/language/javascript/eslint-runtime-names.json +61 -0
  146. package/configurations/language/javascript/manifest.toml +393 -0
  147. package/configurations/language/javascript/rules/BUN.md +13 -0
  148. package/configurations/language/javascript/rules/COMPONENTS.md +18 -0
  149. package/configurations/language/javascript/rules/DENO.md +15 -0
  150. package/configurations/language/javascript/rules/JAVASCRIPT.md +60 -0
  151. package/configurations/language/javascript/rules/NAMING.md +31 -0
  152. package/configurations/language/javascript/rules/NODE.md +21 -0
  153. package/configurations/language/javascript/rules/PLAYWRIGHT.md +34 -0
  154. package/configurations/language/javascript/semgrep/javascript.yml +84 -0
  155. package/configurations/language/markdown/manifest.toml +85 -0
  156. package/configurations/language/markdown/markdownlint-cli2.mjs +19 -0
  157. package/configurations/language/python/manifest.toml +621 -0
  158. package/configurations/language/python/rules/DESIGN.md +136 -0
  159. package/configurations/language/python/rules/FLOW.md +124 -0
  160. package/configurations/language/python/rules/NAMING.md +53 -0
  161. package/configurations/language/python/rules/PACKAGING.md +49 -0
  162. package/configurations/language/python/rules/PYTHON.md +136 -0
  163. package/configurations/language/python/rules/TYPING.md +132 -0
  164. package/configurations/language/sql/manifest.toml +68 -0
  165. package/configurations/language/sql/rules/NAMING.md +90 -0
  166. package/configurations/language/sql/rules/SQL.md +9 -0
  167. package/configurations/language/swift/manifest.toml +164 -0
  168. package/configurations/language/swift/rules/NAMING.md +88 -0
  169. package/configurations/language/swift/rules/SWIFT.md +134 -0
  170. package/configurations/language/swift/rules/SWIFTUI.md +61 -0
  171. package/configurations/language/swift/rules/UIKIT.md +99 -0
  172. package/configurations/language/swift/semgrep/swift.yml +126 -0
  173. package/configurations/language/typescript/eslint-presets.json +215 -0
  174. package/configurations/language/typescript/manifest.toml +72 -0
  175. package/configurations/language/typescript/rules/NAMING.md +73 -0
  176. package/configurations/language/typescript/rules/TYPESCRIPT.md +79 -0
  177. package/configurations/library/drizzle/manifest.toml +68 -0
  178. package/configurations/library/drizzle/rules/DRIZZLE.md +44 -0
  179. package/configurations/library/react-hook-form/manifest.toml +15 -0
  180. package/configurations/library/react-hook-form/rules/REACT-HOOK-FORM.md +48 -0
  181. package/configurations/library/swift-snapshot-testing/manifest.toml +32 -0
  182. package/configurations/library/tanstack-query/eslint-presets.json +21 -0
  183. package/configurations/library/tanstack-query/manifest.toml +26 -0
  184. package/configurations/library/tanstack-query/rules/TANSTACK-QUERY.md +41 -0
  185. package/configurations/library/testing-library/eslint-presets.json +191 -0
  186. package/configurations/library/testing-library/manifest.toml +47 -0
  187. package/configurations/library/translations/manifest.toml +40 -0
  188. package/configurations/library/translations/rules/NEXT-INTL.md +33 -0
  189. package/configurations/library/translations/rules/TRANSLATIONS.md +102 -0
  190. package/configurations/library/trpc/manifest.toml +14 -0
  191. package/configurations/library/trpc/rules/TRPC.md +43 -0
  192. package/configurations/library/zod/manifest.toml +25 -0
  193. package/configurations/library/zod/rules/ZOD.md +44 -0
  194. package/configurations/library/zustand/manifest.toml +18 -0
  195. package/configurations/library/zustand/rules/ZUSTAND.md +106 -0
  196. package/configurations/platform/cloudflare/manifest.toml +94 -0
  197. package/configurations/platform/cloudflare/rules/CLOUDFLARE.md +23 -0
  198. package/configurations/platform/cloudflare/semgrep/cloudflare.yml +12 -0
  199. package/configurations/platform/supabase/manifest.toml +112 -0
  200. package/configurations/platform/supabase/rules/SUPABASE.md +129 -0
  201. package/configurations/platform/supabase/semgrep/supabase.yml +60 -0
  202. package/configurations/testing/jest/manifest.toml +54 -0
  203. package/configurations/testing/pytest/manifest.toml +53 -0
  204. package/configurations/testing/swift-tests/manifest.toml +52 -0
  205. package/configurations/testing/swift-tests/rules/SWIFT-TESTS.md +79 -0
  206. package/configurations/testing/vitest/eslint-presets.json +22 -0
  207. package/configurations/testing/vitest/manifest.toml +69 -0
  208. package/configurations/testing/vitest/rules/VITEST.md +18 -0
  209. package/dist/LICENSE.md +201 -0
  210. package/dist/THIRD-PARTY-NOTICES.md +25 -0
  211. package/dist/eslint-rule-levels.json +10 -0
  212. package/dist/gspot.js +30740 -0
  213. package/dist/linkinator-program.js +65 -0
  214. package/dist/purgecss-program.js +51 -0
  215. package/dist/tool-versions.json +3 -0
  216. package/grammars/bash.wasm +0 -0
  217. package/grammars/css.wasm +0 -0
  218. package/grammars/html.wasm +0 -0
  219. package/grammars/javascript.wasm +0 -0
  220. package/grammars/licenses/tree-sitter-bash.txt +21 -0
  221. package/grammars/licenses/tree-sitter-css.txt +21 -0
  222. package/grammars/licenses/tree-sitter-html.txt +21 -0
  223. package/grammars/licenses/tree-sitter-javascript.txt +21 -0
  224. package/grammars/licenses/tree-sitter-python.txt +21 -0
  225. package/grammars/licenses/tree-sitter-swift.txt +21 -0
  226. package/grammars/licenses/tree-sitter-typescript.txt +21 -0
  227. package/grammars/python.wasm +0 -0
  228. package/grammars/swift.wasm +0 -0
  229. package/grammars/tsx.wasm +0 -0
  230. package/grammars/typescript.wasm +0 -0
  231. package/gspot.schema.json +45991 -0
  232. package/package.json +93 -5
@@ -0,0 +1,393 @@
1
+ allowed_words = ["JavaScript", "ESLint"]
2
+ ignored_folders = ["node_modules", "bower_components"]
3
+
4
+ [prefix_collisions]
5
+ prefixes = ["jsconfig", "eslint", "playwright"]
6
+
7
+ [configuration]
8
+ title = "JavaScript"
9
+ suggests = []
10
+ description = "ESLint with the shipped rule set over every JavaScript file, type checking through JSDoc, and knip for dead code."
11
+
12
+ [detect]
13
+ project_files = ["package.json"]
14
+ extensions = [".js", ".jsx", ".mjs", ".cjs"]
15
+ shebangs = ["node"]
16
+
17
+ [files]
18
+ extensions = [".js", ".jsx", ".mjs", ".cjs"]
19
+ tags = ["shebang:node"]
20
+ eslint_plugins = true
21
+
22
+ [[tool]]
23
+ name = "eslint"
24
+ rule_url = "https://eslint.org/docs/latest/rules/{rule}"
25
+ crash_pattern = "^(?:Oops! Something went wrong|Error: Cannot find module|ERR_MODULE_NOT_FOUND|ConfigError:)"
26
+ diagnostic_header_pattern = "^(?:Oops!|ESLint: )"
27
+ version = "9.39.5"
28
+ npm = "eslint"
29
+ [[tool.replace]]
30
+ file = "eslint.config.js"
31
+ shared = false
32
+
33
+ [[tool.replace]]
34
+ file = "eslint.config.mjs"
35
+ shared = false
36
+
37
+ [[tool.replace]]
38
+ file = "eslint.config.cjs"
39
+ shared = false
40
+
41
+ [[tool.replace]]
42
+ file = "eslint.config.ts"
43
+ shared = false
44
+
45
+ [[tool.replace]]
46
+ file = "eslint.config.mts"
47
+ shared = false
48
+
49
+ [[tool.replace]]
50
+ file = "eslint.config.cts"
51
+ shared = false
52
+
53
+ [[tool.replace]]
54
+ file = ".eslintrc"
55
+ shared = false
56
+
57
+ [[tool.replace]]
58
+ file = ".eslintrc.js"
59
+ shared = false
60
+
61
+ [[tool.replace]]
62
+ file = ".eslintrc.cjs"
63
+ shared = false
64
+
65
+ [[tool.replace]]
66
+ file = ".eslintrc.json"
67
+ shared = false
68
+
69
+ [[tool.replace]]
70
+ file = ".eslintrc.yml"
71
+ shared = false
72
+
73
+ [[tool.replace]]
74
+ file = ".eslintrc.yaml"
75
+ shared = false
76
+
77
+ [[tool.replace]]
78
+ file = ".eslintignore"
79
+ shared = false
80
+
81
+ [[tool.refused_options]]
82
+ paths = ["rules", "overrides", "extends"]
83
+ message = "ESLint rule selection comes from level recommended or all. Use tools.eslint.rules and tools.eslint.override for native options, or gspot ignore javascript/eslint --rule <rule> --reason <why> to accept a finding."
84
+
85
+ [tool.suppression]
86
+ marker = "^(?:/\\*\\s*eslint-disable(?:-next-line|-line)?|//\\s*eslint-disable-(?:next-)?line)(?=\\s|$)"
87
+ reason = " -- (?<reason>\\S.*)"
88
+
89
+ [[tool.replace]]
90
+ file = "package.json"
91
+ key = "eslintConfig"
92
+ shared = true
93
+
94
+ [[tool]]
95
+ name = "@eslint/js"
96
+ kind = "library"
97
+ version = "9.39.5"
98
+ npm = "@eslint/js"
99
+
100
+ [[tool]]
101
+ name = "@gspothq/eslint-plugin"
102
+ rule_prefix = "gspot"
103
+ kind = "library"
104
+ npm = "@gspothq/eslint-plugin"
105
+ rule_url = "https://generativespotting.com/reference/eslint-plugin/{rule}/"
106
+
107
+ [[tool]]
108
+ name = "eslint-plugin-sonarjs"
109
+ rule_prefix = "sonarjs"
110
+ kind = "library"
111
+ version = "4.2.0"
112
+ npm = "eslint-plugin-sonarjs"
113
+
114
+ [[tool]]
115
+ name = "eslint-plugin-unicorn"
116
+ rule_prefix = "unicorn"
117
+ rule_url = "https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/{rule}.md"
118
+ kind = "library"
119
+ version = "65.0.1"
120
+ npm = "eslint-plugin-unicorn"
121
+
122
+ [[tool]]
123
+ name = "eslint-plugin-security"
124
+ rule_prefix = "security"
125
+ kind = "library"
126
+ version = "4.0.1"
127
+ npm = "eslint-plugin-security"
128
+
129
+ [[tool]]
130
+ name = "eslint-plugin-barrel-files"
131
+ rule_prefix = "barrel-files"
132
+ kind = "library"
133
+ version = "3.0.1"
134
+ npm = "eslint-plugin-barrel-files"
135
+
136
+ [[tool]]
137
+ name = "eslint-plugin-perfectionist"
138
+ rule_prefix = "perfectionist"
139
+ kind = "library"
140
+ npm = "eslint-plugin-perfectionist"
141
+ version = "5.12.1"
142
+
143
+ [[tool]]
144
+ name = "eslint-plugin-n"
145
+ rule_prefix = "n"
146
+ kind = "library"
147
+ version = "18.3.0"
148
+ npm = "eslint-plugin-n"
149
+
150
+ [[tool]]
151
+ name = "eslint-plugin-jsdoc"
152
+ rule_prefix = "jsdoc"
153
+ kind = "library"
154
+ version = "64.3.9"
155
+ npm = "eslint-plugin-jsdoc"
156
+
157
+ [[tool]]
158
+ name = "eslint-plugin-regexp"
159
+ rule_prefix = "regexp"
160
+ kind = "library"
161
+ version = "3.3.0"
162
+ npm = "eslint-plugin-regexp"
163
+
164
+ [[tool]]
165
+ name = "eslint-plugin-import-x"
166
+ rule_prefix = "import-x"
167
+ kind = "library"
168
+ version = "4.17.1"
169
+ npm = "eslint-plugin-import-x"
170
+
171
+ [[tool]]
172
+ name = "picomatch"
173
+ kind = "library"
174
+ version = "4.0.7"
175
+ npm = "picomatch"
176
+
177
+ [[tool]]
178
+ name = "eslint-import-resolver-typescript"
179
+ kind = "library"
180
+ version = "4.4.5"
181
+ npm = "eslint-import-resolver-typescript"
182
+
183
+ [[tool]]
184
+ name = "eslint-plugin-boundaries"
185
+ rule_prefix = "boundaries"
186
+ kind = "library"
187
+ version = "7.2.0"
188
+ npm = "eslint-plugin-boundaries"
189
+
190
+ [[tool.when]]
191
+ setting = "architecture.module"
192
+
193
+ [[tool.when]]
194
+ level = "all"
195
+
196
+ [[tool]]
197
+ name = "eslint-plugin-package-json"
198
+ rule_prefix = "package-json"
199
+ kind = "library"
200
+ version = "1.8.0"
201
+ npm = "eslint-plugin-package-json"
202
+
203
+ [[tool]]
204
+ name = "eslint-config-prettier"
205
+ kind = "library"
206
+ version = "10.1.8"
207
+ npm = "eslint-config-prettier"
208
+
209
+ [[tool]]
210
+ name = "globals"
211
+ kind = "library"
212
+ version = "17.12.0"
213
+ npm = "globals"
214
+
215
+ [[tool]]
216
+ name = "knip"
217
+ version = "6.35.1"
218
+ npm = "knip"
219
+ [[tool.replace]]
220
+ file = "knip.json"
221
+ shared = false
222
+
223
+ [[tool.replace]]
224
+ file = "knip.jsonc"
225
+ shared = false
226
+
227
+ [[tool.replace]]
228
+ file = ".knip.json"
229
+ shared = false
230
+
231
+ [[tool.replace]]
232
+ file = ".knip.jsonc"
233
+ shared = false
234
+
235
+ [[tool.replace]]
236
+ file = "knip.ts"
237
+ shared = false
238
+
239
+ [[tool.replace]]
240
+ file = "knip.js"
241
+ shared = false
242
+
243
+ [[tool.replace]]
244
+ file = "knip.config.js"
245
+ shared = false
246
+
247
+ [[tool.replace]]
248
+ file = "knip.config.ts"
249
+ shared = false
250
+
251
+ [[tool]]
252
+ name = "tsc"
253
+ install_hint = "Run: npm install --save-dev typescript"
254
+ system = true
255
+ version = "5.9.3"
256
+ npm = "typescript"
257
+ version_command = ["--version"]
258
+
259
+ [tool.suppression]
260
+ marker = "@ts-(?:ignore|expect-error|nocheck)\\b"
261
+ reason = "@ts-(?:ignore|expect-error|nocheck):?\\s+(?<reason>\\S.*)"
262
+
263
+ [[tool_file]]
264
+ target = ".gspot/config/eslint.config.mjs"
265
+ required_tools = ["@eslint/js", "@gspothq/eslint-plugin", "eslint-plugin-sonarjs", "eslint-plugin-unicorn", "eslint-plugin-security", "eslint-plugin-barrel-files", "eslint-plugin-perfectionist", "eslint-plugin-n", "eslint-plugin-jsdoc", "eslint-plugin-regexp", "eslint-plugin-import-x", "eslint-import-resolver-typescript", "eslint-plugin-boundaries", "eslint-plugin-package-json", "eslint-config-prettier", "globals", "picomatch"]
266
+ scope_fragments = true
267
+ tool = "eslint"
268
+ rule_keys = ["rules"]
269
+
270
+ [tool_file.pointer]
271
+ path = "eslint.config.mjs"
272
+ body = "export { default } from {target_module};"
273
+
274
+ [[tool_file]]
275
+ target = ".gspot/config/jsconfig.json"
276
+ tool = "tsc"
277
+ check = "javascript/tsc"
278
+ per_scope = true
279
+
280
+ [[tool_file]]
281
+ target = ".gspot/config/knip.json"
282
+ tool = "knip"
283
+
284
+ [[check]]
285
+ name = "eslint"
286
+ tool = ["eslint", "node"]
287
+ example = "The declaration `const unused = 1;` reports no-unused-vars. Delete the variable."
288
+ level = "recommended"
289
+ stage = "commit"
290
+ command = ["eslint", "--max-warnings", "0", "--no-warn-ignored", "--config", "{tool_file:eslint}", "--format", "json", "{files}"]
291
+ fix = ["eslint", "--fix", "--config", "{tool_file:eslint}", "{files}"]
292
+ exit_codes = [1]
293
+ summary = "Runs the shipped ESLint rules on JavaScript, TypeScript, component files, and package.json."
294
+ why = "ESLint catches mistakes and dead code the runtime accepts: unused code, unsafe patterns, functions that only forward."
295
+ help = "Run gspot check --fix for the rules that fix themselves, then read each remaining line; gspot explain <rule> links the rule documentation."
296
+
297
+ [check.files]
298
+ extensions = [".js", ".jsx", ".mjs", ".cjs"]
299
+ filenames = ["package.json"]
300
+ tags = ["shebang:node"]
301
+ eslint_plugins = true
302
+
303
+ [check.output]
304
+ format = "json"
305
+ children = "messages"
306
+
307
+ [check.output.fields]
308
+ file = "filePath"
309
+ line = "line"
310
+ column = "column"
311
+ rule = "ruleId"
312
+ message = "message"
313
+ fixable = "fix"
314
+
315
+ [[check]]
316
+ name = "tsc"
317
+ example = "With JavaScript type checking enabled, passing a number to a JSDoc parameter declared as `string` reports a type error. Pass the intended string value or correct the documented parameter contract."
318
+ level = "recommended"
319
+ stage = "push"
320
+ runs = "scope"
321
+ cwd = "scope"
322
+ tool = "tsc"
323
+ summary = "Type-checks plain JavaScript through its JSDoc comments."
324
+ why = "A JavaScript file with a wrong call crashes at run time; the checker sees it first when the types are written down."
325
+ help = "Add or fix the JSDoc type that the error names."
326
+
327
+ [check.files]
328
+ extensions = [".js", ".mjs", ".cjs", ".jsx"]
329
+
330
+ [check.output]
331
+ format = "regex"
332
+ pattern = "^(?<file>[^(]+)\\((?<line>\\d+),(?<column>\\d+)\\): error (?<rule>TS\\d+): (?<message>.*)$"
333
+
334
+ [[check]]
335
+ name = "knip"
336
+ example = "An exported declaration that no selected entry point uses reports an unused export. Remove the export or declaration and update consumers. If the file is dynamically loaded, add its entry point in tools.knip.extra with a reason."
337
+ level = "recommended"
338
+ stage = "push"
339
+ runs = "scope"
340
+ command = ["knip", "--config", "{tool_file:knip}", "--no-progress", "--reporter", "json", "{workspace:--workspace}"]
341
+ cwd = "root"
342
+ summary = "Finds files, exports, and dependencies nothing uses."
343
+ why = "Dead code is read, maintained, and shipped for nobody."
344
+ help = "Delete what knip names, or add a knip entry point in tools.knip.extra with a reason if the file is loaded in a way knip cannot see."
345
+
346
+ [check.output]
347
+ format = "knip"
348
+
349
+ [[naming.override]]
350
+ paths = ["**"]
351
+ languages = ["typescript", "javascript"]
352
+ categories = ["functions", "methods"]
353
+ ignored_prefix = "^handle(?=[A-Z])"
354
+ reason = "A handler starts with handle and then names the event."
355
+
356
+ [rules."PLAYWRIGHT.md"]
357
+ dependencies = ["@playwright/test", "playwright"]
358
+
359
+ [rules."NODE.md"]
360
+ runtimes = ["node"]
361
+ absent_dependencies = ["react-native", "expo"]
362
+
363
+ [rules."DENO.md"]
364
+ runtimes = ["deno"]
365
+
366
+ [rules."COMPONENTS.md"]
367
+ dependencies = ["astro", "svelte", "vue", "react"]
368
+
369
+ [rules."BUN.md"]
370
+ filenames = ["bun.lock", "bun.lockb", "bunfig.toml"]
371
+
372
+ [eslint]
373
+ all_level_rules = ["import-x/first", "import-x/newline-after-import", "barrel-files/avoid-barrel-files", "perfectionist/sort-imports", "perfectionist/sort-named-imports", "perfectionist/sort-exports", "perfectionist/sort-named-exports", "complexity", "import-x/exports-last", "jsdoc/no-types", "jsdoc/require-description", "jsdoc/require-jsdoc", "jsdoc/require-param", "jsdoc/require-param-description", "jsdoc/require-returns", "jsdoc/require-returns-description", "max-depth", "max-lines", "max-lines-per-function", "max-nested-callbacks", "max-params", "max-statements", "n/no-process-exit", "n/prefer-global/buffer", "n/prefer-global/console", "n/prefer-global/process", "n/prefer-global/url", "n/prefer-global/url-search-params", "n/prefer-promises/dns", "n/prefer-promises/fs", "no-console", "no-param-reassign", "package-json/repository-shorthand", "package-json/require-attribution", "package-json/require-description", "package-json/require-exports", "package-json/require-files", "package-json/require-name", "package-json/require-repository", "package-json/require-sideEffects", "package-json/require-type", "package-json/require-version", "package-json/sort-collections", "security/detect-child-process", "security/detect-possible-timing-attacks", "sonarjs/bitwise-operators", "sonarjs/class-name", "sonarjs/cognitive-complexity", "sonarjs/constructor-for-side-effects", "sonarjs/fixme-tag", "sonarjs/hooks-before-test-cases", "sonarjs/max-switch-cases", "sonarjs/no-clear-text-protocols", "sonarjs/no-commented-code", "sonarjs/no-default-utility-imports", "sonarjs/no-fixed-wait-in-tests", "sonarjs/no-global-this", "sonarjs/no-hardcoded-ip", "sonarjs/no-identical-functions", "sonarjs/no-inverted-boolean-check", "sonarjs/no-labels", "sonarjs/no-nested-assignment", "sonarjs/no-nested-conditional", "sonarjs/no-nested-functions", "sonarjs/no-nested-switch", "sonarjs/no-nested-template-literals", "sonarjs/no-os-command-from-path", "sonarjs/no-same-line-conditional", "sonarjs/no-selector-parameter", "sonarjs/no-small-switch", "sonarjs/no-undefined-argument", "sonarjs/parameterized-tests", "sonarjs/prefer-default-last", "sonarjs/prefer-immediate-return", "sonarjs/prefer-native-lodash-alternative", "sonarjs/prefer-object-literal", "sonarjs/prefer-promise-shorthand", "sonarjs/prefer-read-only-props", "sonarjs/prefer-regexp-exec", "sonarjs/prefer-single-boolean-return", "sonarjs/prefer-specific-assertions", "sonarjs/prefer-type-guard", "sonarjs/prefer-while", "sonarjs/pseudo-random", "sonarjs/public-static-readonly", "sonarjs/publicly-writable-directories", "sonarjs/regex-complexity", "sonarjs/todo-tag", "sonarjs/use-type-alias", "unicorn/better-dom-traversing", "unicorn/catch-error-name", "unicorn/consistent-assert", "unicorn/consistent-compound-words", "unicorn/consistent-date-clone", "unicorn/consistent-empty-array-spread", "unicorn/consistent-function-scoping", "unicorn/consistent-json-file-read", "unicorn/consistent-template-literal-escape", "unicorn/dom-node-dataset", "unicorn/expiring-todo-comments", "unicorn/explicit-length-check", "unicorn/isolated-functions", "unicorn/no-anonymous-default-export", "unicorn/no-array-for-each", "unicorn/no-array-from-fill", "unicorn/no-array-method-this-argument", "unicorn/no-array-reduce", "unicorn/no-array-reverse", "unicorn/no-array-sort", "unicorn/no-await-expression-member", "unicorn/no-blob-to-file", "unicorn/no-canvas-to-image", "unicorn/no-confusing-array-splice", "unicorn/no-document-cookie", "unicorn/no-empty-file", "unicorn/no-exports-in-scripts", "unicorn/no-for-loop", "unicorn/no-hex-escape", "unicorn/no-immediate-mutation", "unicorn/no-magic-array-flat-depth", "unicorn/no-named-default", "unicorn/no-negated-condition", "unicorn/no-negation-in-equality-check", "unicorn/no-nested-ternary", "unicorn/no-new-array", "unicorn/no-process-exit", "unicorn/no-single-promise-in-promise-methods", "unicorn/no-static-only-class", "unicorn/no-this-assignment", "unicorn/no-typeof-undefined", "unicorn/no-unnecessary-array-flat-depth", "unicorn/no-unnecessary-array-splice-count", "unicorn/no-unnecessary-nested-ternary", "unicorn/no-unnecessary-slice-end", "unicorn/no-unreadable-array-destructuring", "unicorn/no-unreadable-iife", "unicorn/no-useless-switch-case", "unicorn/prefer-add-event-listener", "unicorn/prefer-array-find", "unicorn/prefer-array-flat", "unicorn/prefer-array-flat-map", "unicorn/prefer-array-index-of", "unicorn/prefer-array-last-methods", "unicorn/prefer-array-some", "unicorn/prefer-at", "unicorn/prefer-bigint-literals", "unicorn/prefer-blob-reading-methods", "unicorn/prefer-class-fields", "unicorn/prefer-classlist-toggle", "unicorn/prefer-date-now", "unicorn/prefer-default-parameters", "unicorn/prefer-dom-node-append", "unicorn/prefer-dom-node-remove", "unicorn/prefer-dom-node-text-content", "unicorn/prefer-event-target", "unicorn/prefer-get-or-insert-computed", "unicorn/prefer-global-this", "unicorn/prefer-includes", "unicorn/prefer-includes-over-repeated-comparisons", "unicorn/prefer-iterator-to-array-at-end", "unicorn/prefer-keyboard-event-key", "unicorn/prefer-logical-operator-over-ternary", "unicorn/prefer-math-abs", "unicorn/prefer-math-min-max", "unicorn/prefer-math-trunc", "unicorn/prefer-modern-dom-apis", "unicorn/prefer-modern-math-apis", "unicorn/prefer-module", "unicorn/prefer-native-coercion-functions", "unicorn/prefer-negative-index", "unicorn/prefer-number-properties", "unicorn/prefer-object-from-entries", "unicorn/prefer-optional-catch-binding", "unicorn/prefer-prototype-methods", "unicorn/prefer-query-selector", "unicorn/prefer-queue-microtask", "unicorn/prefer-reflect-apply", "unicorn/prefer-regexp-test", "unicorn/prefer-response-static-json", "unicorn/prefer-set-has", "unicorn/prefer-set-size", "unicorn/prefer-simple-condition-first", "unicorn/prefer-single-call", "unicorn/prefer-split-limit", "unicorn/prefer-spread", "unicorn/prefer-string-match-all", "unicorn/prefer-string-pad-start-end", "unicorn/prefer-string-raw", "unicorn/prefer-string-repeat", "unicorn/prefer-string-replace-all", "unicorn/prefer-string-slice", "unicorn/prefer-string-starts-ends-with", "unicorn/prefer-string-trim-start-end", "unicorn/prefer-structured-clone", "unicorn/prefer-switch", "unicorn/prefer-ternary", "unicorn/prefer-top-level-await", "unicorn/prefer-type-error", "unicorn/relative-url-style", "unicorn/require-passive-events"]
374
+
375
+ [eslint.presets.eslint]
376
+ package = "@eslint/js"
377
+ source = "configs.recommended"
378
+
379
+ [eslint.presets.sonar]
380
+ package = "eslint-plugin-sonarjs"
381
+ source = "configs.recommended"
382
+
383
+ [eslint.presets.unicorn]
384
+ package = "eslint-plugin-unicorn"
385
+ source = "configs.recommended"
386
+
387
+ [eslint.presets.packageJson]
388
+ package = "eslint-plugin-package-json"
389
+ source = "configs.recommended"
390
+
391
+ [eslint.presets.prettier]
392
+ package = "eslint-config-prettier"
393
+ source = ""
@@ -0,0 +1,13 @@
1
+ # Bun
2
+
3
+ Rules that hold because the code runs on Bun.
4
+
5
+ ## Module resolution
6
+
7
+ - Match internal imports to the project entry point and TypeScript configuration. Bun
8
+ [resolves TypeScript directly](https://bun.sh/docs/runtime/module-resolution), including
9
+ explicit `.ts` imports and extensionless paths. Do not assume the project emits `.js` files.
10
+
11
+ ## APIs
12
+
13
+ - Use a `Bun.*` API only where the project runs on Bun alone, and say so in the file header.
@@ -0,0 +1,18 @@
1
+ # Components
2
+
3
+ These rules cover components in Astro, Svelte, Vue, and React.
4
+
5
+ ## Props and tests
6
+
7
+ - Keep markup declarative. Move an expression longer than one operator into a derived value.
8
+ - Do not reach into a child to change its state.
9
+ - Do not copy a prop into local state and keep the copy updated by hand.
10
+ - Pass the fields a child reads. Avoid passing a whole store or parent object.
11
+ - Test a component through what the application shows to the user and how the user acts, rather than its internal state.
12
+
13
+ ## Component conventions
14
+
15
+ <!-- level: all -->
16
+
17
+ - One component has one job. Split a component when its markup holds two unrelated regions.
18
+ - Name a component in PascalCase and name the file the same.
@@ -0,0 +1,15 @@
1
+ # Deno
2
+
3
+ Rules that hold because the code runs on Deno.
4
+
5
+ ## Module resolution
6
+
7
+ - Relative imports use the real file extension, such as `.ts` or `.js`. Preserve aliases
8
+ resolved by the declared import map.
9
+
10
+ ## Permissions and APIs
11
+
12
+ - Deno grants permissions explicitly. Request the narrowest set the code needs. Write the reason
13
+ in a comment beside the permission flag.
14
+ - Use `Deno.*` and the web platform APIs. Node built-ins use the compatibility layer.
15
+ Write the reason for using one in a comment beside its import.
@@ -0,0 +1,60 @@
1
+ # JavaScript
2
+
3
+ Keep development tooling out of production runtime imports. Keep inputs and side effects explicit.
4
+ Validate external values where the program receives them, before sending them to a database or another service.
5
+ These values include HTTP bodies, query strings, route params, headers, environment variables, and database rows.
6
+ Also validate remote procedure call results, provider responses, file input, generated data sources, webhooks, and scheduled-job payloads.
7
+ If a check and this file disagree, tell the user.
8
+
9
+ ## Runtime
10
+
11
+ Use APIs supported by the runtime and version the project declares. Browser code targets the
12
+ browsers and build pipeline the project declares. Before adding a build step that needs another
13
+ runtime, update the declared runtime configuration and documentation.
14
+
15
+ ## Modules
16
+
17
+ Keep existing CommonJS modules CommonJS unless the task includes migrating them. Keep side-effect
18
+ imports rare and explain their required effect. Browser code imports no server implementation.
19
+
20
+ ### Module conventions
21
+
22
+ <!-- level: all -->
23
+
24
+ - Prefer named imports and named exports.
25
+ - Avoid mutable exports and default exports in application modules. Preserve a default export
26
+ when a tool or framework requires it.
27
+ - Do not create container classes or exported objects only to simulate a namespace.
28
+ - Keep JSDoc `@typedef` declarations with their behavioral owner, following the project's folder
29
+ arrangement. Share them through type imports when another module needs the contract.
30
+ - Import the module that declares a symbol. A library can explicitly select index-only re-exports.
31
+
32
+ ## Values
33
+
34
+ - Use frozen objects or plain constant objects for fixed value sets.
35
+ - Avoid truthiness checks when `0`, `''`, `false`, `null`, and `undefined` mean different things.
36
+ - Use `null` for a meaningful domain value and `undefined` for missing object properties.
37
+ - Use `??` when only `null` and `undefined` require a fallback. Do not use `||` when an empty
38
+ string, zero, or false has a valid meaning.
39
+ - Name regular expressions after the value or contract they validate.
40
+ - Check indexed reads when a value can have no result.
41
+
42
+ ## Objects and functions
43
+
44
+ Use object literals for grouped arguments and destructure fields when it makes their use clearer.
45
+ A function that mutates its input names and documents that effect.
46
+
47
+ ### Function conventions
48
+
49
+ <!-- level: all -->
50
+
51
+ - Use an options object for several related arguments.
52
+ - Do not add optional parameters to hide a broken caller contract.
53
+ - Use early returns when they make missing-value and error handling clearer.
54
+ - Keep constructors small. Add inheritance only for a real runtime relationship.
55
+ - Use decorators only where a framework requires them.
56
+
57
+ ## Asynchronous work
58
+
59
+ Await a promise that must finish before the next step. Release child processes, subscriptions,
60
+ and other resources in `finally` or the API's cleanup mechanism.
@@ -0,0 +1,31 @@
1
+ # JavaScript Naming
2
+
3
+ JavaScript naming follows the same role, responsibility, and boundary principles
4
+ as TypeScript. Use the JavaScript rules when editing `.js`, `.mjs`, `.cjs`, and
5
+ plain JavaScript tooling files.
6
+
7
+ ## JavaScript imports and exports
8
+
9
+ <!-- level: all -->
10
+
11
+ - Namespace import aliases derive from the imported filename or
12
+ clear package name.
13
+ - Named imports keep their exported name unless a collision forces an alias.
14
+ - If the module requires a named import alias, use a domain or path component that
15
+ explains the collision.
16
+ - Default import names follow the imported identifier type, but use default
17
+ imports only for ecosystem modules that require them.
18
+
19
+ Use `fileOne` for a namespace import from `file-one.js`. If two modules export
20
+ `Cat`, use an alias such as `DomesticatedCat` that identifies the owning domain.
21
+
22
+ ## JavaScript and TypeScript files
23
+
24
+ <!-- level: all -->
25
+
26
+ | Avoid | Prefer | Meaning |
27
+ | ---------------- | ----------------------------- | ------------------------------ |
28
+ | `Helpers.js` | `session-token-verifier.js` | Session token verification. |
29
+ | `UserService.ts` | `user-repository.ts` | User persistence. |
30
+ | `sharedUtils.ts` | `email-template-formatter.ts` | Email template formatting. |
31
+ | `data.cjs` | `database-connection.cjs` | Database connection lifecycle. |
@@ -0,0 +1,21 @@
1
+ # Node
2
+
3
+ Rules that hold because the code runs on Node, whatever language the project uses.
4
+
5
+ ## Module resolution
6
+
7
+ - Unbundled compiled TypeScript follows Node module resolution. Runtime imports must resolve
8
+ in the emitted output; a `.js` import can identify the corresponding TypeScript source.
9
+ - Preserve the declared bundler or direct TypeScript execution contract when the project uses one.
10
+ - Do not rely on CommonJS and ES module interop working by accident. A file declares its module format,
11
+ through the package type field or its extension.
12
+
13
+ ## Global variables
14
+
15
+ - Use `process`, `Buffer`, and Node built-ins. Node also provides version-specific
16
+ [web-compatible globals](https://nodejs.org/api/globals.html), including `fetch`.
17
+ DOM globals such as `window` and `document` require a browser environment.
18
+
19
+ ## Processes
20
+
21
+ - Give a directly invoked script a shebang and executable permissions.
@@ -0,0 +1,34 @@
1
+ # Playwright
2
+
3
+ ## Tests
4
+
5
+ - Give each test a coherent user journey with independent setup and observable assertions.
6
+ - Query by role and accessible name such as `getByRole('button', { name: 'Submit' })`, then by label,
7
+ placeholder, or text.
8
+ - Do not use fixed waits such as `waitForTimeout`. Wait for the visible state, response, or URL that proves
9
+ the operation completed. Network inactivity alone does not establish readiness.
10
+ - Every test starts from a known state it creates through the application's real setup (API or
11
+ UI), not from shared seed data or another test's leftovers.
12
+ - Assertions use the auto-retrying `expect(locator)` matchers. No manual polling loops.
13
+ - A test never reads or writes production data. The base URL and credentials come from the
14
+ project configuration for each environment.
15
+
16
+ ## Test data and page objects
17
+
18
+ - Keep shared setup in the test support folder. Introduce page objects only when
19
+ several tests repeat the same interactions.
20
+ - Reuse isolated authentication state for tests that do not exercise login. Login tests verify
21
+ the actual authentication journey. Keep account state isolated between concurrent workers.
22
+
23
+ ## Configuration
24
+
25
+ - Use the configuration files declared by the repository. Name projects so failures identify
26
+ their browser, viewport, or other relevant execution context.
27
+ - Declare the retry policy in the project configuration. Report retried passes separately from
28
+ first-attempt passes.
29
+ - Configure trace, screenshot, and video retention for the required diagnostics. Upload failure
30
+ artifacts, restrict access, and avoid capturing credentials or unrelated private data.
31
+ - Enable parallel execution only when each test has its own accounts and mutable resources.
32
+ Document any scenario that requires serial execution.
33
+ - Test the production build for release acceptance. Use a development server only when development
34
+ the test covers that behavior.