79 lines
1.6 KiB
Markdown
79 lines
1.6 KiB
Markdown
---
|
|
publish: true
|
|
permalink: /os/hyprshutdown
|
|
title: hyprshutdown
|
|
created: 2026-02-05T09:31:46.735-07:00
|
|
modified: 2026-02-05T12:18:16.847-07:00
|
|
tags:
|
|
- hyprland
|
|
- shutdown
|
|
cssclasses: ""
|
|
---
|
|
|
|
hyprshutdown provides graceful shutdown/reboot with animated transitions for Hyprland.
|
|
|
|
## Installation
|
|
|
|
**From AUR:**
|
|
```bash
|
|
paru -S hyprshutdown
|
|
```
|
|
|
|
**Build from source** (if AUR is outdated):
|
|
```bash
|
|
git clone https://github.com/hyprwm/hyprshutdown
|
|
cd hyprshutdown
|
|
cmake .
|
|
make all
|
|
sudo make install
|
|
```
|
|
|
|
## Usage
|
|
|
|
```bash
|
|
# Shutdown with animation
|
|
hyprshutdown -t "Shutting down..." --post-cmd "shutdown -P 0"
|
|
|
|
# Reboot with animation
|
|
hyprshutdown -t "Restarting..." --post-cmd "reboot"
|
|
|
|
# Custom timeout (ms)
|
|
hyprshutdown -t "Goodbye!" --timeout 2000 --post-cmd "shutdown -P 0"
|
|
```
|
|
|
|
## Options
|
|
|
|
| Option | Description |
|
|
|--------|-------------|
|
|
| `-t, --text` | Message to display during animation |
|
|
| `--post-cmd` | Command to run after animation completes |
|
|
| `--timeout` | Animation duration in milliseconds |
|
|
|
|
## Integration
|
|
|
|
### Hyprland keybind
|
|
|
|
```bash
|
|
bind = $mainMod, M, exec, command -v hyprshutdown >/dev/null 2>&1 && hyprshutdown || hyprctl dispatch exit
|
|
```
|
|
|
|
### Ashell settings
|
|
|
|
In ashell config:
|
|
```toml
|
|
[settings]
|
|
shutdown_cmd = "hyprshutdown -t 'Shutting down...' --post-cmd 'shutdown -P 0'"
|
|
reboot_cmd = "hyprshutdown -t 'Restarting...' --post-cmd 'reboot'"
|
|
```
|
|
|
|
## Fallback
|
|
|
|
If hyprshutdown isn't installed, fall back to regular exit:
|
|
```bash
|
|
command -v hyprshutdown >/dev/null 2>&1 && hyprshutdown || hyprctl dispatch exit
|
|
```
|
|
|
|
## Resources
|
|
|
|
- GitHub: https://github.com/hyprwm/hyprshutdown
|