#!/usr/bin/bash if [[ "$1" == "poweroff" ]]; then doas poweroff elif [[ "$1" == "reboot" ]]; then doas reboot fi