eslint-plugin-file-progress
Advanced tools
Comparing version 2.0.1 to 2.1.0
@@ -1,5 +0,3 @@ | ||
import type { Rule } from 'eslint'; | ||
import type { Linter, Rule } from 'eslint'; | ||
export = plugin; | ||
declare const plugin: { | ||
@@ -10,3 +8,5 @@ meta: { | ||
}; | ||
configs: {}; | ||
configs: { | ||
recommended: Linter.Config | ||
}; | ||
rules: { | ||
@@ -16,1 +16,4 @@ activate: Rule.RuleModule; | ||
}; | ||
export const recommended: Linter.Config; | ||
export = plugin; |
30
index.js
@@ -6,3 +6,3 @@ import progress from './rules/progress.js'; | ||
name: "eslint-plugin-file-progress", | ||
version: "2.0.1" | ||
version: "2.1.0" | ||
}, | ||
@@ -15,2 +15,30 @@ configs: {}, | ||
const configs = { | ||
recommended: { | ||
name: 'recommended', | ||
plugins: { | ||
progress: plugin | ||
}, | ||
rules: { | ||
"progress/activate": 2 | ||
} | ||
}, | ||
noCI: { | ||
name: 'no-ci', | ||
plugins: { | ||
progress: plugin | ||
}, | ||
rules: { | ||
"progress/activate": 2 | ||
}, | ||
settings: { | ||
progress: { | ||
hide: process.env.CI === 'true' | ||
} | ||
} | ||
} | ||
} | ||
Object.assign(plugin.configs, configs) | ||
export default plugin |
{ | ||
"name": "eslint-plugin-file-progress", | ||
"description": "Eslint plugin to print file progress", | ||
"version": "2.0.1", | ||
"version": "2.1.0", | ||
"license": "MIT", | ||
@@ -6,0 +6,0 @@ "author": "sibiraj-s", |
@@ -34,3 +34,3 @@ # eslint-plugin-file-progress | ||
progress: { | ||
hide: false, | ||
hide: false, // use this to hide the progress message, can be useful in CI | ||
successMessage: "Lint done..." | ||
@@ -42,2 +42,26 @@ } | ||
Or use the recommended config | ||
```js | ||
// eslint.config.js | ||
import progress from 'eslint-plugin-file-progress' | ||
export default [ | ||
progress.configs.recommended | ||
] | ||
``` | ||
or if you want to hide the progress message in CI | ||
```js | ||
// eslint.config.js | ||
import progress from 'eslint-plugin-file-progress' | ||
export default [ | ||
progress.configs.noCI | ||
] | ||
``` | ||
CI is detected by checking if the `CI` environment variable is set to `true`. | ||
### Demo | ||
@@ -44,0 +68,0 @@ |
@@ -52,10 +52,3 @@ import path from 'node:path'; | ||
messages: [], | ||
schema: [ | ||
{ | ||
oneOf: [ | ||
{ type: 'string', enum: ['0', '1', 'off'] }, | ||
{ type: 'number', enum: [0, 1] } | ||
] | ||
} | ||
] | ||
schema: [] | ||
}, | ||
@@ -62,0 +55,0 @@ create, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6594
100
91
2