Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ee61ab6

Browse filesBrowse files
ralishaddaleax
authored andcommitted
repl: improve doc for disabling REPL history on Windows
Environment variables with empty values are not permitted on Windows. As such, to disable persistent REPL history one or more spaces should be used. Node will trim whitespace from the variable, resulting in a blank variable at runtime and the desired behaviour. PR-URL: #25672 Fixes: #25661 Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com> Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
1 parent 3c5a7a2 commit ee61ab6
Copy full SHA for ee61ab6

File tree

Expand file treeCollapse file tree

1 file changed

+4
-2
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-2
lines changed
Open diff view settings
Collapse file

‎doc/api/repl.md‎

Copy file name to clipboardExpand all lines: doc/api/repl.md
+4-2Lines changed: 4 additions & 2 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -540,8 +540,10 @@ environment variables:
540540

541541
- `NODE_REPL_HISTORY` - When a valid path is given, persistent REPL history
542542
will be saved to the specified file rather than `.node_repl_history` in the
543-
user's home directory. Setting this value to `''` will disable persistent
544-
REPL history. Whitespace will be trimmed from the value.
543+
user's home directory. Setting this value to `''` (an empty string) will
544+
disable persistent REPL history. Whitespace will be trimmed from the value.
545+
On Windows platforms environment variables with empty values are invalid so
546+
set this variable to one or more spaces to disable persistent REPL history.
545547
- `NODE_REPL_HISTORY_SIZE` - Controls how many lines of history will be
546548
persisted if history is available. Must be a positive number.
547549
**Default:** `1000`.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.