371309b
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
371309b
From: Peter Jones <pjones@redhat.com>
371309b
Date: Fri, 31 Aug 2018 16:42:03 -0400
371309b
Subject: [PATCH] Make "reset" an alias for the "reboot" command.
371309b
371309b
I'm really tired of half the tools I get to use having one and the other half
371309b
having the other.
371309b
371309b
Signed-off-by: Peter Jones <pjones@redhat.com>
371309b
---
371309b
 grub-core/commands/reboot.c | 11 +++++++----
371309b
 1 file changed, 7 insertions(+), 4 deletions(-)
371309b
371309b
diff --git a/grub-core/commands/reboot.c b/grub-core/commands/reboot.c
371309b
index 46d364c99a9..f5cc2283636 100644
371309b
--- a/grub-core/commands/reboot.c
371309b
+++ b/grub-core/commands/reboot.c
371309b
@@ -32,15 +32,18 @@ grub_cmd_reboot (grub_command_t cmd __attribute__ ((unused)),
371309b
   grub_reboot ();
371309b
 }
371309b
 
371309b
-static grub_command_t cmd;
371309b
+static grub_command_t reboot_cmd, reset_cmd;
371309b
 
371309b
 GRUB_MOD_INIT(reboot)
371309b
 {
371309b
-  cmd = grub_register_command ("reboot", grub_cmd_reboot,
371309b
-			       0, N_("Reboot the computer."));
371309b
+  reboot_cmd = grub_register_command ("reboot", grub_cmd_reboot,
371309b
+				      0, N_("Reboot the computer."));
371309b
+  reset_cmd = grub_register_command ("reset", grub_cmd_reboot,
371309b
+				     0, N_("Reboot the computer."));
371309b
 }
371309b
 
371309b
 GRUB_MOD_FINI(reboot)
371309b
 {
371309b
-  grub_unregister_command (cmd);
371309b
+  grub_unregister_command (reboot_cmd);
371309b
+  grub_unregister_command (reset_cmd);
371309b
 }