Get mail user

You want to get the mail user!

To get the mail user, you can use the getpwuid function in Python, which returns a tuple containing the username, real name, home directory, shell, and other information about the user.

Here's an example:

import pwd

user = pwd.getpwuid(os.getuid())
print(user.pw_name)  # prints the username

Alternatively, you can use the getlogin function, which returns the username of the current user:

import getpass

username = getpass.getlogin()
print(username)

Note that getlogin may not work on all systems, especially if the user is not logged in.

Also, if you're using a Unix-like system, you can use the whoami command to get the current user's username:

whoami

This will print the username of the current user.