-Ingroup vs --Ingroup

Instead of:

sudo adduser --ingroup hadoopgroup hadoopuser

I did a:

sudo adduser -ingroup hadoopgroup hadoopuser

am OK to go? Or the single - will cause a problematic user.

1 Answer

adduser is a Perl script, using Getopt::Long. Unless explicitly told to do so, Getopt::Long will accept single-hyphen long options, and adduser doesn't tell it do so. So, -ingroup will work just as well as --ingroup.

Don't rely on this to work in the future, though.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Marcus Vance

Marcus Vance

Cybersecurity & Digital Privacy Researcher

Marcus Vance is a cybersecurity auditor and technology writer dedicated to educating the public about online safety, data privacy regulations, enterprise security, and emerging cyber threats.

Share this article
Twitter Facebook Pinterest