? CHANGELOG ? shutdown.patch Index: reboot.8 =================================================================== RCS file: /cvs/cygwin-apps/shutdown/reboot.8,v retrieving revision 1.1 diff -u -p -r1.1 reboot.8 --- reboot.8 21 Mar 2013 11:58:00 -0000 1.1 +++ reboot.8 25 Mar 2013 11:26:12 -0000 @@ -19,7 +19,7 @@ reboot, halt, poweroff, hibernate, suspe .B suspend [\fIoptions\fR] .SH DESCRIPTION -These programs allow to +These programs allow the user to .BR reboot ", " halt ", " poweroff ", " hibernate " or " suspend the system. .PP @@ -30,7 +30,7 @@ They are aliases for \fBshutdown --reboo Forces the execution. This can cause applications to lose data. .TP \fB\-x\fR, \fB\-\-exitex\fR -Use ExitWindowsEx rather than InitateSystemShutdown. +Use ExitWindowsEx rather than InitiateSystemShutdownEx. .TP \fB\-\-help\fR Display a help text and exit. Index: shutdown.8 =================================================================== RCS file: /cvs/cygwin-apps/shutdown/shutdown.8,v retrieving revision 1.1 diff -u -p -r1.1 shutdown.8 --- shutdown.8 21 Mar 2013 11:58:00 -0000 1.1 +++ shutdown.8 25 Mar 2013 11:26:12 -0000 @@ -26,23 +26,29 @@ which specifies the time on the 24hr clo \fB\-f\fR, \fB\-\-force\fR Forces the execution. This can cause applications to lose data. .TP -\fB\-s\fR, \fB\-\-shutdown\fR +\fB\-h\fR, \fB\-\-halt\fR The system will shutdown and power off. This is the default action. The system must support the power-off feature, but most systems do. .TP +\fB\-s\fR, \fB\-\-shutdown\fR +Same as --halt. Here for compatibility with the Windows shutdown command line tool. +.TP \fB\-r\fR, \fB\-\-reboot\fR The system will shutdown and then restart. .TP -\fB\-h\fR, \fB\-\-hibernate\fR +\fB\-b\fR, \fB\-\-hibernate\fR The system will suspend to disk. The system must support the hibernate feature. .TP \fB\-p\fR, \fB\-\-suspend\fR The system will suspend to RAM. This is also known as sleep or standby. The system must support the suspend feature. .TP -\fB\-a\fR, \fB\-\-abort\fR +\fB\-c\fR, \fB\-\-cancel\fR Aborts the execution of formerly started shutdown or reboot. .TP +\fB\-a\fR, \fB\-\-abort\fR +Same as --cancel. Here for compatibility with the Windows shutdown command line tool. +.TP \fB\-x\fR, \fB\-\-exitex\fR -Use ExitWindowsEx rather than InitateSystemShutdown. +Use ExitWindowsEx rather than InitiateSystemShutdownEx. .TP \fB\-\-help\fR Display a help text and exit. Index: shutdown.c =================================================================== RCS file: /cvs/cygwin-apps/shutdown/shutdown.c,v retrieving revision 1.4 diff -u -p -r1.4 shutdown.c --- shutdown.c 21 Mar 2013 11:58:35 -0000 1.4 +++ shutdown.c 25 Mar 2013 11:26:12 -0000 @@ -63,12 +63,14 @@ usage_shutdown (void) printf ("Usage: %s [OPTION]... time\n", myname); printf ("Bring the system down.\n\n"); printf (" -f, --force Forces the execution.\n"); + printf (" -h, --halt The system will shutdown and power off (if supported)\n"); printf (" -s, --shutdown The system will shutdown and power off (if supported)\n"); printf (" -r, --reboot The system will reboot.\n"); - printf (" -h, --hibernate The system will suspend to disk (if supported)\n"); + printf (" -b, --hibernate The system will suspend to disk (if supported)\n"); printf (" -p, --suspend The system will suspend to RAM (if supported)\n"); + printf (" -c, --cancel Aborts execution of formerly started shutdown.\n"); printf (" -a, --abort Aborts execution of formerly started shutdown.\n"); - printf (" -x, --exitex Use ExitWindowsEx rather than InitateSystemShutdown.\n"); + printf (" -x, --exitex Use ExitWindowsEx rather than InitiateSystemShutdownEx.\n"); printf (" --help Display this help and exit.\n"); printf (" --version Output version information and exit.\n"); printf ("\n`time' is either the time in seconds or `+' and the time in minutes or a\n"); @@ -98,7 +100,7 @@ usage_reboot (void) } printf (" -f, --force Forces the execution.\n"); - printf (" -x, --exitex Use ExitWindowsEx rather than InitateSystemShutdown.\n"); + printf (" -x, --exitex Use ExitWindowsEx rather than InitiateSystemShutdownEx.\n"); printf (" --help Display this help and exit.\n"); printf (" --version Output version information and exit.\n"); return 0; @@ -166,18 +168,20 @@ parse_cmdline_shutdown(int argc, char ** { struct option longopts[] = { {"abort", no_argument, NULL, 'a'}, + {"cancel", no_argument, NULL, 'c'}, {"exitex", no_argument, NULL, 'x'}, {"force", no_argument, NULL, 'f'}, {"shutdown", no_argument, NULL, 's'}, + {"halt", no_argument, NULL, 'h'}, {"reboot", no_argument, NULL, 'r'}, - {"hibernate", no_argument, NULL, 'h'}, + {"hibernate", no_argument, NULL, 'b'}, {"suspend", no_argument, NULL, 'p'}, {"help", no_argument, NULL, 'H'}, {"version", no_argument, NULL, 'v'}, {0, no_argument, NULL, 0} }; - char opts[] = "axfsrhp"; + char opts[] = "acxfshrbp"; int c; char *arg, *endptr; @@ -188,18 +192,20 @@ parse_cmdline_shutdown(int argc, char ** force = EWX_FORCE; break; case 's': + case 'h': action = EWX_POWEROFF; break; case 'r': action = EWX_REBOOT; break; - case 'h': + case 'b': action = HIBERNATE; break; case 'p': action = SUSPEND; break; case 'a': + case 'c': action = ABORT; break; case 'x':