summaryrefslogtreecommitdiffstats
path: root/park-disk
blob: 58f6aff61d5f1a428fbc779b48494fa2a4fb0342 (plain)
1
2
3
4
5
6
#!/bin/bash
_sudo=''
[[ -z "$1" ]] && { echo "Usage: $(basename "$0") <device>"; exit 1; }
[[ ${UID} -ne 0 ]] && _sudo='sudo'

exec ${_sudo} udisksctl power-off -b "$1"