File tree 2 files changed +5
-0
lines changed
2 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -428,6 +428,7 @@ const success = await lintStaged({
428
428
allowEmpty: false,
429
429
concurrent: true,
430
430
configPath: ' ./path/to/configuration/file' ,
431
+ cwd: process.cwd (),
431
432
debug: false,
432
433
maxArgLength: null,
433
434
quiet: false,
@@ -445,6 +446,7 @@ const success = await lintStaged({
445
446
allowEmpty: false,
446
447
concurrent: true,
447
448
config: { ' *.js' : ' eslint --fix' },
449
+ cwd: process.cwd (),
448
450
debug: false,
449
451
maxArgLength: null,
450
452
quiet: false,
Original file line number Diff line number Diff line change @@ -48,6 +48,7 @@ function loadConfig(configPath) {
48
48
* @param {boolean | number } [options.concurrent] - The number of tasks to run concurrently, or false to run tasks serially
49
49
* @param {object } [options.config] - Object with configuration for programmatic API
50
50
* @param {string } [options.configPath] - Path to configuration file
51
+ * @param {Object } [options.cwd] - Current working directory
51
52
* @param {boolean } [options.debug] - Enable debug mode
52
53
* @param {number } [options.maxArgLength] - Maximum argument string length
53
54
* @param {boolean } [options.quiet] - Disable lint-staged’s own console output
@@ -65,6 +66,7 @@ module.exports = async function lintStaged(
65
66
concurrent = true ,
66
67
config : configObject ,
67
68
configPath,
69
+ cwd = process . cwd ( ) ,
68
70
debug = false ,
69
71
maxArgLength,
70
72
quiet = false ,
@@ -107,6 +109,7 @@ module.exports = async function lintStaged(
107
109
allowEmpty,
108
110
concurrent,
109
111
config,
112
+ cwd,
110
113
debug,
111
114
maxArgLength,
112
115
quiet,
You can’t perform that action at this time.
0 commit comments