[Pre]tty-HTML: A CLI parser for HTML. Pretty print HTML inputs to Unix stdout.
Project description
[Pre]tty-HTML
[Pre]tty-html: (the logo reads as: 'pookie html') A minimalist python script to pretty print html docs to unix terminal. Pipe the output of html generators to tty-html, for a neat terminal render (than a hard to decode xml dump).
Usage
The program is intended to be just a simple Unix CLI utility. One can specify any html file as an input or pipe an html dump to the stdin of tty-html to get a readable pretty print.
# for detailed usage
$ tty-html --help
...
# format from an html file
$ tty-html index.html
...
# format from stdin
$ curl https://some-website.com/blog -s | tty-html
...
Installation
Easy! There're three ways
1. Compiled binary
head over to the release page and download the binary. make it executable. Thats it. (optionally add it to a bin path of your choice)
2. Using PIP
If you got pip, feel free to install using
pip install tty-html
3. Build from source
If you are nerdy enough, there is a Makefile :), get a c compiler, install python3 and cython, and go for the following commands in order
# transpile script to c
make
# compile the c
make compile
for detailed use case : make help :)
Usage Gallery
-
the raw html
-
the formatted one
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tty_html-1.0.2.tar.gz.
File metadata
- Download URL: tty_html-1.0.2.tar.gz
- Upload date:
- Size: 43.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1f83f59cdedf504d96ea76c781d6cc835ebb91a7af3a18dba3ab7f5e762f0a04
|
|
| MD5 |
163ecd6ea772a39963375323f98ccb2f
|
|
| BLAKE2b-256 |
124d8392d96d8882ba1b9ce3048216c467a8b9c3b11638de9857b7fd8da1a7f8
|
File details
Details for the file tty_html-1.0.2-py3-none-any.whl.
File metadata
- Download URL: tty_html-1.0.2-py3-none-any.whl
- Upload date:
- Size: 30.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f11228766bda53d772de8aac893ea22b14186dfd6d55ecee17f18e9b761079fc
|
|
| MD5 |
4b7d4166ef6c29d567bbb00056b4f2ea
|
|
| BLAKE2b-256 |
6e7768f785dbf74243b8d5b45bcc07aa258c5e9c887766acd6e48201bf691495
|