tbl - cat for csv files
tbl lets you print out csv files to your terminal, formatted and "prettified".
A lot of the hard work is done with the rapidtables package, check it out!
| cat | tbl |
|---|---|
Check out this recorded example:
Requirements
- Python 3.4+
Installation
pip install --user clitbl
Usage options
Use tbl -h / tbl --help to see help.
- The most common use it to just print the table
tbl file.csv
--headers
The headers options lets you explicitly specify the headers for the table. Use this option when you csv files does not include headers, (e.g exampleFile
tbl file.csv --headers '#Index#Item#Cost#Tax#Total'
--select
The select options lets you select what columns to print (similar to SQL SELECT)
tbl file.csv --select '#Item#Tax'
❗ Both headers and select use the first charcter as a separator,
it can be any character (kinda like a sed expressions)
❗ The headers specified with this option are case-sensitive
🌟 The headers and select headers can be used together
--format(defualt: rstgrid)
The format options lets you specify the format used when printing the table.
The available formats are:
| rstgrid | rst | md | simple |
|---|---|---|---|
Restrictions
There are several cases tbl does not support:
- Duplicated headers, all headers must be distinct
- Very long headers, while tbl can wrap long paragraph of text in a cell, it cannot wrap text in the headers, which may lead to disfigured output
❗ This is not the use case for tbl anyway, but dont try to print huge tables (several GBs), as tbl (and rapidtable) read the entire table to memory before printing
* Example csv were downloaded from here
Metadata
Release files for clitbl 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| clitbl-0.0.1.tar.gz | 3.8 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| clitbl-0.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.9 kB
Release files / clitbl-0.0.1.tar.gz
| Download URL | clitbl-0.0.1.tar.gz |
|---|---|
| Size | 3.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ca40e0501dc4b9af5a79994a14008bd42adb33d9794a5589fdc40b4358ec0a24
|
|
BLAKE2b-256 checksum How to use checksums |
b433df49001cb5bca5f1867b0feffa000c9a0fff1281cd27277e2a0be6da7a08
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.0
|
Release files / clitbl-0.0.1-py3-none-any.whl
| Download URL | clitbl-0.0.1-py3-none-any.whl |
|---|---|
| Size | 5.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
88b4a89cbd858abfbfe8af3841fb60d1d29f6f953d12b755622e2f8e1d9df788
|
|
BLAKE2b-256 checksum How to use checksums |
86f032e194a2e791cda0294cc0396fb8f2a9462905dea933efb03cb489972128
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.0
|
Security for clitbl 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.