From 5e7e4bc02b51898aa3b09011035d28d6f90bb18e Mon Sep 17 00:00:00 2001 From: Sam Ko Date: Tue, 9 Apr 2024 10:28:12 -0700 Subject: [PATCH] chore(cli): fix the order `--experimental-debug-memory-usage` so it's alphabetical (#64264) ## Why? This fixes the ordering of `--experimental-debug-memory-usage` so the help output for experimental options are alphabetical/ordered properly (grouped at the end). - Related https://github.com/vercel/next.js/pull/63869 Closes NEXT-3054 --- packages/next/src/bin/next.ts | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/next/src/bin/next.ts b/packages/next/src/bin/next.ts index 60f62b5fae..af81e31b5c 100755 --- a/packages/next/src/bin/next.ts +++ b/packages/next/src/bin/next.ts @@ -105,13 +105,10 @@ program )}` ) .option('-d, --debug', 'Enables a more verbose build output.') - .option( - '--experimental-debug-memory-usage', - 'Enables memory profiling features to debug memory consumption.' - ) - .option('--profile', 'Enables production profiling for React.') + .option('--no-lint', 'Disables linting.') .option('--no-mangling', 'Disables mangling.') + .option('--profile', 'Enables production profiling for React.') .option('--experimental-app-only', 'Builds only App Router routes.') .addOption(new Option('--experimental-turbo').hideHelp()) .addOption( @@ -122,6 +119,10 @@ program .choices(['compile', 'generate']) .default('default') ) + .option( + '--experimental-debug-memory-usage', + 'Enables memory profiling features to debug memory consumption.' + ) .action((directory, options) => // ensure process exits after build completes so open handles/connections // don't cause process to hang