#!/bin/bash # omarchy:summary=Restore Omarchy to the package install (undo omarchy-dev-link) # omarchy:group=dev set -euo pipefail if [[ $EUID -eq 0 ]]; then echo "Error: run omarchy-dev-unlink as your user, not under sudo." >&2 exit 1 fi if [[ ${1:-} == "-h" || ${1:-} == "--help" ]]; then cat </dev/null 2>&1 && hyprctl version &>/dev/null; then hyprctl setenv OMARCHY_PATH /usr/share/omarchy >/dev/null hyprctl setenv PATH "$PATH" >/dev/null echo " Updated Hyprland session env." systemctl --user import-environment OMARCHY_PATH PATH 2>/dev/null || true echo " Updated systemd --user env." if pgrep -x quickshell >/dev/null 2>&1; then omarchy-restart-shell echo " Restarted omarchy-shell." fi hyprctl reload >/dev/null echo " Reloaded Hyprland config." fi echo echo "Done. Existing shells still have the old OMARCHY_PATH until restarted."