Skip to content

Resume Recovery

on-resume is the post-suspend recovery hook used by the Hypr host overrides. It restarts small desktop services that tend to go stale after sleep and refreshes git-related bar caches.

Both desktop and laptop host hypridle.conf files call on-resume from after_sleep_cmd after waking the display:

after_sleep_cmd = sleep 1 && omarchy-system-wake && on-resume

The laptop host also re-arms keyboard backlight handling before on-resume.

You can run the recovery manually without auto-opening Twitch streams with the shared binding:

SUPER+SHIFT+W

Or from a terminal:

Terminal window
on-resume

on-resume detaches itself, writes a fresh log, then:

  • Stops twitch-notifications.
  • Clears Waybar git module cache files under ${XDG_CACHE_HOME:-~/.cache}/waybar.
  • Clears the dot upstream fetch cache under ${XDG_CACHE_HOME:-~/.cache}/dot/fetch-upstream.
  • Restarts Waybar through uwsm-app.
  • Gracefully restarts twitch-notifications in auto-open mode.

The SUPER+SHIFT+W binding passes --no-auto-open, so manual recovery restarts Twitch without opening live channels.

The log is written to:

${XDG_STATE_HOME:-~/.local/state}/on-resume.log

Use this when the machine wakes but the bar or desktop helpers look stale:

  1. Press SUPER+SHIFT+W, or run on-resume.
  2. Wait for Waybar to disappear and return.
  3. If something still looks wrong, read ~/.local/state/on-resume.log.

If Waybar does not return, run it directly to surface errors:

Terminal window
uwsm-app -- waybar

If git status in the bar stays stale, remove the caches and run recovery again:

Terminal window
rm -f ~/.cache/waybar/git-*-waybar.json ~/.cache/waybar/git-*-waybar.json.tmp
rm -rf ~/.cache/dot/fetch-upstream
on-resume