Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
src: simplify --debug flags
Any use of --debug, --debug=, --debug-brk, or --debug-brk=
now triggers an error. That means we can eliminate their
aliases with --inspect counterparts and simplify the code.

PR-URL: #28615
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
  • Loading branch information
cjihrig committed Jul 13, 2019
commit 2c5716bd725dcead2b9fe5f66f22fb8cd932cb5a
8 changes: 3 additions & 5 deletions src/node_options.cc
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,9 @@ DebugOptionsParser::DebugOptionsParser() {
AddAlias("--inspect=", { "--inspect-port", "--inspect" });

AddOption("--debug", "", &DebugOptions::deprecated_debug);
AddAlias("--debug=", { "--inspect-port", "--debug" });
AddAlias("--debug=", "--debug");
AddOption("--debug-brk", "", &DebugOptions::deprecated_debug);
AddAlias("--debug-brk=", "--debug-brk");

AddOption("--inspect-brk",
"activate inspector on host:port and break at start of user script",
Expand All @@ -283,10 +285,6 @@ DebugOptionsParser::DebugOptionsParser() {
Implies("--inspect-brk-node", "--inspect");
AddAlias("--inspect-brk-node=", { "--inspect-port", "--inspect-brk-node" });

AddOption("--debug-brk", "", &DebugOptions::break_first_line);
Implies("--debug-brk", "--debug");
AddAlias("--debug-brk=", { "--inspect-port", "--debug-brk" });

AddOption("--inspect-publish-uid",
"comma separated list of destinations for inspector uid"
"(default: stderr,http)",
Expand Down