This is another, larger example, where I actually stumbled on this when looking into Apache Airflow project. Below makes it confusing to see what is actually required and what not. Unless you look for square brackets. Would be it much nicer to list required ones explicitly rather than looking into options and figuring out which one is a must?
usage: airflow users create [-h] -e EMAIL -f FIRSTNAME -l LASTNAME [-p PASSWORD] -r ROLE [--use-random-password] -u USERNAME
Create a user
optional arguments:
-h, --help show this help message and exit
-e EMAIL, --email EMAIL
Email of the user
-f FIRSTNAME, --firstname FIRSTNAME
First name of the user
-l LASTNAME, --lastname LASTNAME
Last name of the user
-p PASSWORD, --password PASSWORD
Password of the user, required to create a user without --use-random-password
-r ROLE, --role ROLE Role of the user. Existing roles include Admin, User, Op, Viewer, and Public
--use-random-password
Do not prompt for password. Use random string instead. Required to create a user without --password
-u USERNAME, --username USERNAME
Username of the user
examples:
To create an user with "Admin" role and username equals to "admin", run:
$ airflow users create \
--username admin \
--firstname FIRST_NAME \
--lastname LAST_NAME \
--role Admin \
--email admin@example.org
airflow users create command error: the following arguments are required: -e/--email, -f/--firstname, -l/--lastname, -r/--role, -u/--username, see help above.
|