How-to Create a new user for use with the PostgreSQL DB on Mac OS
Open the terminal from: Applications\Utilities\Terminal — See help link open link below for assistance Mac OS How-to Open Terminal
Type command below from the terminal createuser -P -d appname — In this command, you used createuser to create a role named appname. The -d flag gave the role the permission to create new databases.
login to postgres with following command from terminal: psql postgres
Your terminal will look like this below with postgres=#
While you’re logged in to psql, type the following to check to see the list of users in database
postgres=#\du;