.login_stuff 316 B

12345678910111213141516
  1. #!/bin/sh
  2. if tty | grep "/dev/tty1"; then
  3. if ! Hyprland; then
  4. echo "Something went wrong. Going to console."
  5. else
  6. clear
  7. echo "Closed without errors. Shut down? [Y/n]"
  8. read -r shutdown
  9. if [ "$shutdown" = "y" ]; then
  10. loginctl poweroff
  11. fi
  12. fi
  13. fi