mirror of
https://github.com/affaan-m/ECC.git
synced 2026-10-21 15:31:46 +02:00
Extract contained-fs (TOCTOU-safe fs ops) and json-ops helpers into scripts/lib/install/. install-lifecycle 2453->1957 lines, public API unchanged (66/0 lifecycle tests pass). Harden tests/run-all.js with exit-code-first verdict, TAP fallback, file-level counts and filter arg. Add warn-level eslint guards (prefer-const, complexity, max-depth, max-params). Split test scripts into test:validators/test:js/test:python and coverage:js/coverage:python.
41 lines
1.1 KiB
JavaScript
41 lines
1.1 KiB
JavaScript
const js = require('@eslint/js');
|
|
const globals = require('globals');
|
|
|
|
module.exports = [
|
|
{
|
|
ignores: ['.opencode/dist/**', '.cursor/**', 'node_modules/**', '.venv/**', 'venv/**', 'coverage/**', 'workflows/**/*.workflow.*', '.claude/workflows/**']
|
|
},
|
|
js.configs.recommended,
|
|
{
|
|
languageOptions: {
|
|
ecmaVersion: 2022,
|
|
sourceType: 'commonjs',
|
|
globals: {
|
|
...globals.node,
|
|
...globals.es2022
|
|
}
|
|
},
|
|
rules: {
|
|
'no-unused-vars': ['error', {
|
|
argsIgnorePattern: '^_',
|
|
varsIgnorePattern: '^_',
|
|
caughtErrorsIgnorePattern: '^_'
|
|
}],
|
|
'no-undef': 'error',
|
|
'eqeqeq': 'warn',
|
|
'prefer-const': 'warn',
|
|
'no-var': 'warn',
|
|
'no-console': 'off',
|
|
'complexity': ['warn', 20],
|
|
'max-depth': ['warn', 5],
|
|
'max-params': ['warn', 6]
|
|
}
|
|
},
|
|
{
|
|
files: ['**/*.mjs'],
|
|
languageOptions: {
|
|
sourceType: 'module'
|
|
}
|
|
}
|
|
];
|