[cmdline] Show commands in alphabetical order

Commands were originally ordered by functional group (e.g. keeping the
image management commands together), with arrays used to impose a
functionally meaningful order within the group.

As the number of commands and functional groups has expanded over the
years, this has become essentially useless as an organising principle.
Switch to sorting commands alphabetically (using the linker table
mechanism).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2025-08-06 16:29:32 +01:00
parent 332241238e
commit 9d4a2ee353
49 changed files with 104 additions and 423 deletions
+1 -4
View File
@@ -95,7 +95,4 @@ static int cpuid_exec ( int argc, char **argv ) {
}
/** x86 CPU feature detection command */
struct command cpuid_command __command = {
.name = "cpuid",
.exec = cpuid_exec,
};
COMMAND ( cpuid, cpuid_exec );
+2 -10
View File
@@ -105,13 +105,5 @@ static int stoppxe_exec ( int argc __unused, char **argv __unused ) {
}
/** PXE commands */
struct command pxe_commands[] __command = {
{
.name = "startpxe",
.exec = startpxe_exec,
},
{
.name = "stoppxe",
.exec = stoppxe_exec,
},
};
COMMAND ( startpxe, startpxe_exec );
COMMAND ( stoppxe, stoppxe_exec );