Python interface to the POSIX getent family of commands
Project description
Python interface to the POSIX getent family of commands (getpwent, getgrent, getnetent, etc.)
Usage
Here a few examples.
Load the interface:
>>> import getent
Doing a passwd lookup:
>>> print dict(getent.passwd('root')) {'dir': '/root', 'gecos': 'root', 'gid': 0, 'name': 'root', 'password': 'x', 'shell': '/bin/bash', 'uid': 0}
Doing a group lookup:
>>> print dict(getent.group('root')) {'gid': 0, 'members': [], 'name': 'root', 'password': 'x'}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
getent-0.1.tar.gz
(4.7 kB
view details)
File details
Details for the file getent-0.1.tar.gz
.
File metadata
- Download URL: getent-0.1.tar.gz
- Upload date:
- Size: 4.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5298c05423dc874100786d4fc0862d848c5062728dd1f6e647dabfdf7ca4467e |
|
MD5 | 6ccaeb58538b34601feba0a2359dbc45 |
|
BLAKE2b-256 | 825b13970ba1633db7203e8b927e73846fce4f8cea13a8dc056043e44e7dc806 |