Welcome
This is a repository that holds my implementation of the tail -f command.
In order to install it you can use either of these two ways.
git clone https://github.com/r3ap3rpy/pytail
cd pytail
python setup.py install
OR
pip install pytail-r3ap3rpy
Usage
Simply specify the file or filter to use the tool.
╰─>$ pytail --file test.txt
##############################
# Tailing file: test.txt
# Use <CTRL + C> to exit
##############################
2024-02-15 13:42:35.747232 :: line
2024-02-15 13:42:40.425967 :: another
2024-02-15 13:42:44.374841 :: yet another
##############################
# End of tailing!
# Elapsed time: 15.93 second(s)!
# Speed: 0.19 lps (lines per second)
##############################
Notes
If you install it in a virtualenv it will just work fine!
On MacOS systems the module works fine.
On linux systems if you install the module with sudo it will work fine, if you install it without sudo you may have to issue the following command after install if you cannot find the pytail executable.
export PATH="$HOME/.local/bin:$PATH"
On windows in case the pytail executable is not available after install you have to use the absolute path to use it.
python C:\Python\Python310\Scripts\pytail --file test.txt
There are two arguments:
- file (The file you want to tail!)
- filter (Optional, allows you to get only lines that contain the filter, case-insensitive!)
ToDo
- Check install issues!
- Add automatic version bump to workflow
- Add permission check to see if user has the right to read the file!
- Change it to use argparse
- Add versioning
- Add switches
Release files for pytail-r3ap3rpy 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pytail_r3ap3rpy-0.1.5.tar.gz | 3.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pytail_r3ap3rpy-0.1.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 6.6 kB
Release files / pytail_r3ap3rpy-0.1.5.tar.gz
| Download URL | pytail_r3ap3rpy-0.1.5.tar.gz |
|---|---|
| Size | 3.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b6b2844574dc6e3dc0077cac631fb1c56a4917149cbe0f59b58a182a9e016361
|
|
BLAKE2b-256 checksum How to use checksums |
9b1dc9d7c5d3b2bbcd2dcef5ecabf8cb613436ebe5c5a0c2dde841e9e6545f9a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.12.3
|
Release files / pytail_r3ap3rpy-0.1.5-py3-none-any.whl
| Download URL | pytail_r3ap3rpy-0.1.5-py3-none-any.whl |
|---|---|
| Size | 3.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fc9220748063dd569a725eb07c42a724256d5a9cce024aa4627915d3def6c76c
|
|
BLAKE2b-256 checksum How to use checksums |
e681b8bddb6215ea27466edd333473446fda8338625e0ade8d45607d9200f344
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.12.3
|