Skip to content

Commit fc93cc9

Browse files
richardlaucodebytere
authored andcommittedOct 1, 2020
module: drop -u alias for --conditions
Old versions of mocha break after nodejs/node#34637. This was a bug in mocha, but since this is a widely used module we can expect ecosystem breakage until modules are updated to the latest version of mocha. Drop the conflicting `-u` alias -- we can potentially bring it back once modules have been updated. PR-URL: nodejs/node#34935 Backport-PR-URL: nodejs/node#35385 Refs: mochajs/mocha#4417 Refs: nodejs/node#34637 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Jan Krems <jan.krems@gmail.com> Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com> Reviewed-By: Myles Borins <myles.borins@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Shelley Vohr <codebytere@gmail.com>
1 parent 740c958 commit fc93cc9

File tree

4 files changed

+4
-5
lines changed

4 files changed

+4
-5
lines changed
 

‎doc/api/cli.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ $ node --completion-bash > node_bash_completion
8181
$ source node_bash_completion
8282
```
8383

84-
### `-u`, `--conditions=condition`
84+
### `--conditions=condition`
8585
<!-- YAML
8686
added: REPLACEME
8787
-->
@@ -1181,7 +1181,7 @@ node --require "./a.js" --require "./b.js"
11811181

11821182
Node.js options that are allowed are:
11831183
<!-- node-options-node start -->
1184-
* `--conditions`, `-u`
1184+
* `--conditions`
11851185
* `--diagnostic-dir`
11861186
* `--disable-proto`
11871187
* `--enable-fips`

‎doc/node.1

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ Aborting instead of exiting causes a core file to be generated for analysis.
7878
.It Fl -completion-bash
7979
Print source-able bash completion script for Node.js.
8080
.
81-
.It Fl u , Fl -conditions Ar string
81+
.It Fl -conditions Ar string
8282
Use custom conditional exports conditions
8383
.Ar string
8484
.

‎src/node_options.cc

-1
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,6 @@ EnvironmentOptionsParser::EnvironmentOptionsParser() {
287287
"additional user conditions for conditional exports and imports",
288288
&EnvironmentOptions::conditions,
289289
kAllowedInEnvironment);
290-
AddAlias("-u", "--conditions");
291290
AddOption("--diagnostic-dir",
292291
"set dir for all output files"
293292
" (default: current working directory)",

‎test/es-module/test-esm-custom-exports.mjs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Flags: --conditions=custom-condition -u another
1+
// Flags: --conditions=custom-condition --conditions another
22
import { mustCall } from '../common/index.mjs';
33
import { strictEqual } from 'assert';
44
import { requireFixture, importFixture } from '../fixtures/pkgexports.mjs';

0 commit comments

Comments
 (0)
Failed to load comments.