dstromberg@zareason-strata7440 ~/src/home-svn/readline0/trunk $ /usr/local/cpython-3.6/bin/python3
Python 3.6.0 (default, Apr 22 2017, 09:17:19)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import readline0
>>> file_ = open('/etc/shells', 'r')
>>> for line in readline0.readline0(file_=file_, separator=b'\n'):
... print(line)
...
b'# /etc/shells: valid login shells'
b'/bin/sh'
b'/bin/dash'
b'/bin/bash'
b'/bin/rbash'
>>>
You can e-mail the author with questions or comments: