Skip to main content

Get the macOS console username and/or a list of local non-system users.

Project description

macusers

Get the macOS console username and/or a list of local non-system users.

>>> import macusers
>>> macusers.console()
'bryanheinz'
>>> macusers.users()
['root', 'bryanheinz']
>>> macusers.users(False)
['bryanheinz']

This module is used to get the current or last (if the system currently doesn't have any logged in users) logged in console user on macOS instead of the user running the script/program. This module can also return a list of all local non-system created users.

Installing

You can install macusers using pip. macusers has been tested with Python 3.7 and 3.9.

> python3 -m pip install macusers

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

macusers-0.0.3.tar.gz (2.5 kB view hashes)

Uploaded source

Built Distribution

macusers-0.0.3-py3-none-any.whl (3.3 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page