Skip to content

Commit f664b7b

Browse files
src: unflag --experimental-default-config
1 parent bba07d7 commit f664b7b

File tree

4 files changed

+7
-20
lines changed

4 files changed

+7
-20
lines changed

doc/api/cli.md

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -920,8 +920,11 @@ added:
920920
> Stability: 1.0 - Early development
921921
922922
If present, Node.js will look for a configuration file at the specified path.
923-
Node.js will read the configuration file and apply the settings. The
924-
configuration file should be a JSON file with the following structure. `vX.Y.Z`
923+
Node.js will read the configuration file and apply the settings.
924+
Unless `--no-experimental-default-config-file` flag is present, Node.js will look for a
925+
`node.config.json` file in the current working directory and load it as a
926+
as configuration file.
927+
The configuration file should be a JSON file with the following structure. `vX.Y.Z`
925928
in the `$schema` must be replaced with the version of Node.js you are using.
926929

927930
```json
@@ -980,20 +983,6 @@ unknown keys or keys that cannot be used in a namespace.
980983
Node.js will not sanitize or perform validation on the user-provided configuration,
981984
so **NEVER** use untrusted configuration files.
982985

983-
### `--experimental-default-config-file`
984-
985-
<!-- YAML
986-
added:
987-
- v23.10.0
988-
- v22.16.0
989-
-->
990-
991-
> Stability: 1.0 - Early development
992-
993-
If the `--experimental-default-config-file` flag is present, Node.js will look for a
994-
`node.config.json` file in the current working directory and load it as a
995-
as configuration file.
996-
997986
### `--experimental-eventsource`
998987

999988
<!-- YAML

lib/internal/process/pre_execution.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -338,8 +338,7 @@ function setupSQLite() {
338338
}
339339

340340
function initializeConfigFileSupport() {
341-
if (getOptionValue('--experimental-default-config-file') ||
342-
getOptionValue('--experimental-config-file')) {
341+
if (getOptionValue('--experimental-config-file')) {
343342
emitExperimentalWarning('--experimental-config-file');
344343
}
345344
}

lib/internal/test_runner/runner.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,6 @@ const kFilterArgs = [
102102
'--test',
103103
'--experimental-test-coverage',
104104
'--watch',
105-
'--experimental-default-config-file',
106105
'--experimental-config-file',
107106
];
108107
const kFilterArgValues = ['--test-reporter', '--test-reporter-destination'];

src/node_options.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ class EnvironmentOptions : public Options {
261261
bool report_exclude_env = false;
262262
bool report_exclude_network = false;
263263
std::string experimental_config_file_path;
264-
bool experimental_default_config_file = false;
264+
bool experimental_default_config_file = true;
265265

266266
inline DebugOptions* get_debug_options() { return &debug_options_; }
267267
inline const DebugOptions& debug_options() const { return debug_options_; }

0 commit comments

Comments
 (0)