snazzer icon indicating copy to clipboard operation
snazzer copied to clipboard

--help needs root permissions

Open rumpelsepp opened this issue 9 years ago • 1 comments

$ ./snazzer --help
[sudo] password for stefan:

--help should not ask for root permissions.

rumpelsepp avatar Nov 26 '15 09:11 rumpelsepp

The offending line appears to be if ! $SUDO test -e "$SNAZZER_SUBVOLS_EXCLUDE_FILE"; then $SUDO is set to sudo if snazzer is not being run as root.

I believe the sudo is there because $SNAZZER_SUBVOLS_EXCLUDE_FILE defaults to /etc/snazzer/exclude.patterns

Is there a better solution than moving the case check for --help to be above these lines?

jamiereid avatar Dec 19 '16 10:12 jamiereid