added sudo check before running script