Shadows the system
reboot binary and refuses to run if tmux or screen sessions are alive on the machine.
- Shell 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| bin | ||
| README.md | ||
reboot
Shadows the system reboot binary and refuses to run if tmux or screen
sessions are alive on the machine.
Installation
tpm install reboot
Make sure ~/.tpm/bin is prepended to your PATH, otherwise the real
binary wins.
Usage
reboot # checks for sessions, then sudo reboot
If a tmux or screen session is running:
error: des sessions sont en cours : tmux
0: 3 windows (created Mon Aug 31 10:12:04 2026)
error: détache ou ferme ces sessions avant de relancer reboot
Notes
- Sessions are detected with
pgrepacross all users, not just yours — a reboot kills everyone's sessions. - The real binary is called with
sudoand an absolute path, so you will be asked for your password. This is intentional (no NOPASSWD): it also prevents accidentally rebooting from a shell history misclick. - Works over interactive SSH sessions.
ssh host rebootis not supported (no TTY for sudo, and.zshrcis not sourced) — connect first, then run the command.