24. whoami - muneeb-mbytes/linux_course GitHub Wiki

whoami

It is basically the concatenation of the strings "who","am","i" as whoami. It displays the username of the current user when this command is invoked.

Syntax : whoami

The below figure shows output of whoami command, which display name of the currently logged user.

whoami

                                            Figure.1. whoami output

The below GIF shows the whole process from sourcing scripting file till the output.

whoami

                                            GIF.1. whoami output GIF

Link to GitHub lab:https://github.com/muneeb-mbytes/linux_course/blob/b7_team_kachori/whoami/whoami.csh


whoami --help

To list all whoami command options, type whoami --help. The system lists all available options.


To learn passwd command: https://github.com/muneeb-mbytes/linux_course/wiki/25.-passwd-command