@@ -2347,155 +2347,6 @@ void LoadEnvironment(Environment* env) {
23472347 }
23482348}
23492349
2350- static void PrintHelp () {
2351- printf (" Usage: node [options] [ -e script | script.js | - ] [arguments]\n "
2352- " node inspect script.js [arguments]\n "
2353- " \n "
2354- " Options:\n "
2355- " - script read from stdin (default; \n "
2356- " interactive mode if a tty)\n "
2357- " -- indicate the end of node options\n "
2358- " --abort-on-uncaught-exception\n "
2359- " aborting instead of exiting causes a\n "
2360- " core file to be generated for analysis\n "
2361- #if HAVE_OPENSSL && NODE_FIPS_MODE
2362- " --enable-fips enable FIPS crypto at startup\n "
2363- #endif // NODE_FIPS_MODE && NODE_FIPS_MODE
2364- " --experimental-modules experimental ES Module support\n "
2365- " and caching modules\n "
2366- " --experimental-repl-await experimental await keyword support\n "
2367- " in REPL\n "
2368- " --experimental-vm-modules experimental ES Module support\n "
2369- " in vm module\n "
2370- " --experimental-worker experimental threaded Worker support\n "
2371- #if HAVE_OPENSSL && NODE_FIPS_MODE
2372- " --force-fips force FIPS crypto (cannot be disabled)\n "
2373- #endif // HAVE_OPENSSL && NODE_FIPS_MODE
2374- #if defined(NODE_HAVE_I18N_SUPPORT)
2375- " --icu-data-dir=dir set ICU data load path to dir\n "
2376- " (overrides NODE_ICU_DATA)\n "
2377- #if !defined(NODE_HAVE_SMALL_ICU)
2378- " note: linked-in ICU data is present\n "
2379- #endif
2380- #endif // defined(NODE_HAVE_I18N_SUPPORT)
2381- #if HAVE_INSPECTOR
2382- " --inspect-brk[=[host:]port]\n "
2383- " activate inspector on host:port\n "
2384- " and break at start of user script\n "
2385- " --inspect-port=[host:]port\n "
2386- " set host:port for inspector\n "
2387- " --inspect[=[host:]port] activate inspector on host:port\n "
2388- " (default: 127.0.0.1:9229)\n "
2389- #endif // HAVE_INSPECTOR
2390- " --loader=file (with --experimental-modules) use the \n "
2391- " specified file as a custom loader\n "
2392- " for ECMAScript Modules \n "
2393- " --napi-modules load N-API modules (no-op - option\n "
2394- " kept for compatibility)\n "
2395- " --no-deprecation silence deprecation warnings\n "
2396- " --no-force-async-hooks-checks\n "
2397- " disable checks for async_hooks\n "
2398- " --no-warnings silence all process warnings\n "
2399- #if HAVE_OPENSSL
2400- " --openssl-config=file load OpenSSL configuration from the\n "
2401- " specified file (overrides\n "
2402- " OPENSSL_CONF)\n "
2403- #endif // HAVE_OPENSSL
2404- " --pending-deprecation emit pending deprecation warnings\n "
2405- " --preserve-symlinks preserve symbolic links when resolving\n "
2406- " --preserve-symlinks-main preserve symbolic links when resolving\n "
2407- " the main module\n "
2408- " --prof generate V8 profiler output\n "
2409- " --prof-process process V8 profiler output generated\n "
2410- " using --prof\n "
2411- " --redirect-warnings=file\n "
2412- " write warnings to file instead of\n "
2413- " stderr\n "
2414- " --throw-deprecation throw an exception on deprecations\n "
2415- " --title=title the process title to use on start up\n "
2416- #if HAVE_OPENSSL
2417- " --tls-cipher-list=val use an alternative default TLS cipher "
2418- " list\n "
2419- #endif // HAVE_OPENSSL
2420- " --trace-deprecation show stack traces on deprecations\n "
2421- " --trace-event-categories comma separated list of trace event\n "
2422- " categories to record\n "
2423- " --trace-event-file-pattern Template string specifying the\n "
2424- " filepath for the trace-events data, it\n "
2425- " supports ${rotation} and ${pid}\n "
2426- " log-rotation id. %%2$u is the pid.\n "
2427- " --trace-events-enabled track trace events\n "
2428- " --trace-sync-io show stack trace when use of sync IO\n "
2429- " is detected after the first tick\n "
2430- " --trace-warnings show stack traces on process warnings\n "
2431- " --track-heap-objects track heap object allocations for heap "
2432- " snapshots\n "
2433- #if HAVE_OPENSSL
2434- " --use-bundled-ca use bundled CA store"
2435- #if !defined(NODE_OPENSSL_CERT_STORE)
2436- " (default)"
2437- #endif
2438- " \n "
2439- " --use-openssl-ca use OpenSSL's default CA store"
2440- #if defined(NODE_OPENSSL_CERT_STORE)
2441- " (default)"
2442- #endif
2443- #endif // HAVE_OPENSSL
2444- " \n "
2445- " --v8-options print v8 command line options\n "
2446- " --v8-pool-size=num set v8's thread pool size\n "
2447- " --zero-fill-buffers automatically zero-fill all newly "
2448- " allocated\n "
2449- " Buffer and SlowBuffer instances\n "
2450- " -c, --check syntax check script without executing\n "
2451- " -e, --eval script evaluate script\n "
2452- " -h, --help print node command line options\n "
2453- " -i, --interactive always enter the REPL even if stdin\n "
2454- " does not appear to be a terminal\n "
2455- " -p, --print evaluate script and print result\n "
2456- " -r, --require module to preload (option can be "
2457- " repeated)\n "
2458- " -v, --version print Node.js version\n "
2459- " \n "
2460- " Environment variables:\n "
2461- " NODE_DEBUG ','-separated list of core modules\n "
2462- " that should print debug information\n "
2463- " NODE_DEBUG_NATIVE ','-separated list of C++ core debug\n "
2464- " categories that should print debug\n "
2465- " output\n "
2466- " NODE_DISABLE_COLORS set to 1 to disable colors in the REPL\n "
2467- " NODE_EXTRA_CA_CERTS path to additional CA certificates\n "
2468- " file\n "
2469- #if defined(NODE_HAVE_I18N_SUPPORT)
2470- " NODE_ICU_DATA data path for ICU (Intl object) data\n "
2471- #if !defined(NODE_HAVE_SMALL_ICU)
2472- " (will extend linked-in data)\n "
2473- #endif
2474- #endif // defined(NODE_HAVE_I18N_SUPPORT)
2475- " NODE_NO_WARNINGS set to 1 to silence process warnings\n "
2476- #if !defined(NODE_WITHOUT_NODE_OPTIONS)
2477- " NODE_OPTIONS set CLI options in the environment\n "
2478- " via a space-separated list\n "
2479- #endif // !defined(NODE_WITHOUT_NODE_OPTIONS)
2480- #ifdef _WIN32
2481- " NODE_PATH ';'-separated list of directories\n "
2482- #else
2483- " NODE_PATH ':'-separated list of directories\n "
2484- #endif
2485- " prefixed to the module search path\n "
2486- " NODE_PENDING_DEPRECATION set to 1 to emit pending deprecation\n "
2487- " warnings\n "
2488- " NODE_PRESERVE_SYMLINKS set to 1 to preserve symbolic links\n "
2489- " when resolving and caching modules\n "
2490- " NODE_REDIRECT_WARNINGS write warnings to path instead of\n "
2491- " stderr\n "
2492- " NODE_REPL_HISTORY path to the persistent REPL history\n "
2493- " file\n "
2494- " OPENSSL_CONF load OpenSSL configuration from file\n "
2495- " \n "
2496- " Documentation can be found at https://nodejs.org/\n " );
2497- }
2498-
24992350
25002351static void StartInspector (Environment* env, const char * path,
25012352 std::shared_ptr<DebugOptions> debug_options) {
@@ -2771,11 +2622,6 @@ void ProcessArgv(std::vector<std::string>* args,
27712622 exit (0 );
27722623 }
27732624
2774- if (per_process_opts->print_help ) {
2775- PrintHelp ();
2776- exit (0 );
2777- }
2778-
27792625 if (per_process_opts->print_v8_help ) {
27802626 V8::SetFlagsFromString (" --help" , 6 );
27812627 exit (0 );
0 commit comments