File: pwuid.py

package info (click to toggle)
python-cffi 2.0.0~b1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,796 kB
  • sloc: python: 28,456; ansic: 15,272; asm: 116; makefile: 97; sh: 14
file content (8 lines) | stat: -rw-r--r-- 205 bytes parent folder | download
1
2
3
4
5
6
7
8
from __future__ import print_function
import sys, os

# run pwuid_build first, then make sure the shared object is on sys.path
from _pwuid_cffi import ffi, lib


print(ffi.string(lib.getpwuid(0).pw_name))