DS bash – check that script is being executed by root ~~ August 24, 2019 12345if [ $EUID -ne 0 ] then /bin/echo $'\nThis script must be run as the root user!\n' exit fi Related Posts:bash: for - looping over and processing files in…bash - awk with colored outputbash OSX iTerm2 - display inline images in terminal.DS_Store - BASH shell - Linux/OSX = Find & Remove Filesbash OSX: hours on a computer, list rebootsOSX review login items via bash+applescriptbash - du to get space used by directoryApple Mail - control mail check intervalBASH y/n select - on user input