EDIT: As Artur Meinild explained, the options you're asking about are for the command useradd
, not for the command adduser
. This can be confusing, even linux.die.net shows the man page for useradd
on the page for adduser
. The following is about useradd
. If you're looking for the options that adduser
understands, you can find them on the man page for adduser
.
A very valuable tool for using any Linux system are the man pages, short for "manual pages". You can typically reach them on the command line with man name_of_the_command
, for example man ls
or man useradd
. Not every command comes with a man pages, but very many do, especially the more common and basic ones. Additionally, you can find many man pages online, for example the man pages for useradd
.
There are other forms of documentation, as well, for example when you get into programming and are using a third-party library. It is generally a good idea to read up on any command you find anywhere and look into what it's actually doing. If you're just go copy and paste, almost like a magic incantation, you'll probably run into bad suprises rather quickly.
In this specific case, the man page for useradd
says about the additional options used in
sudo useradd -m -c "Alex Hales" -s /bin/bash Alex
the following:
-m, --create-home
Create the user's home directory if it does not exist. The files and directories contained in the skeleton directory (which can be defined with the -k option) will be copied to the home directory.
useradd will create the home directory unless CREATE_HOME in /etc/login.defs is set to no.
and
-c, --comment COMMENT
Any text string. It is generally a short description of the login, and is currently used as the field for the user's full name.
and
-s, --shell SHELL
The name of the user's login shell. The default is to leave this field blank, which causes the system to select the default login shell specified by the SHELL variable in /etc/default/useradd, or an empty string by default.