shutdown就是关机。
出了关机,还有什么?
使用方法:
- -s
- 关机。
shutdown -s
- -r
- 重启。
shutdown -r
- -t
- 指定操作时间。以秒计,默认30。
shutdown -s -t xx
shutdown -r -t xx
- 但不要
shutdown -t xx
。
- -a
- 取消操作。只能在倒计时时用。
shutdown -a
- -?
- 显示帮助。
上面几个选项只是shutdown用法中很小的一部分,全部用法如下:
可以写在*.bat文件里:
shutdown -s -t 60
也可以用在C++里: