It is very simple implementation of the unix shell utility `tail`
Project description
PyTAILer
PyTAILer is very simple implementation of the unix shell utility tail
.
from pytailer import fail_tail
with fail_tail("some_file.txt", lines=10) as tail:
for line in tail: # be careful: infinite loop!
print(line)
Of course, you can use async version:
import asyncio
from pytailer import async_fail_tail
async def main():
with async_fail_tail("some_file.txt", lines=10) as tail:
async for line in tail: # be careful: infinite loop!
print(line)
asyncio.run(main()) # python 3.7+
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
pytailer-0.1.0.tar.gz
(2.9 kB
view hashes)