rwx/sh/id.sh

10 lines
133 B
Bash
Raw Permalink Normal View History

2025-07-27 19:12:00 +02:00
# id
# check if current user is root
#| id
rwx_id_root() {
local user_id
user_id="$(id -u)"
[ "${user_id}" -eq 0 ] || return 1
}