A simple CLI utility for generating formatted text headers with borders and boxes.
Project description
hfmt-cli
A simple CLI utility for generating formatted text headers with borders and boxes.
📦 Requirements
- Python >= 3.9
🛠 Usage
Run with a positional argument:
$ hfmt "project title"
################################## project title ###################################
Run with flags:
$ hfmt --head "build complete" --style multi --char "=" --width 60 --upper --align left
============================================================
= BUILD COMPLETE
============================================================
$ hfmt --border-only --width 50
##################################################
Run with box mode:
$ hfmt --title --width auto --box double "welcome back"
╔══════════════╗
║ Welcome Back ║
╚══════════════╝
⚙️ Options
hfmt-cli supports the following value flags:
| Flag | Description | Default |
|---|---|---|
head (positional) |
Header text | — |
-H, --head |
Header text (alternative flag form) | — |
-s, --style |
Border style (single, multi) |
single |
-c, --char |
Character to use for the border | # |
-w, --width |
Width of the rows | 84 or auto |
-a, --align |
Header justification | center or left |
-b, --box |
Surround header by a box (overrides other flags) | none |
hfmt-cli supports the following value toggles:
| Toggle | Description |
|---|---|
-U, --upper |
Converts header to "UPPER_CASE" |
-L, --lower |
Converts header to "lower_case" |
-T, --title |
Converts header to "Title_Case" |
-S, --swapcase |
Converts header to "sWAP_cASE" |
--border-only |
Returns only a border of characters with no header |
🚀 Installation
Install via pipx (recommended)
pipx install hfmt-cli
Install via pip:
pip install hfmt-cli
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 hfmt_cli-0.1.1.tar.gz.
File metadata
- Download URL: hfmt_cli-0.1.1.tar.gz
- Upload date:
- Size: 5.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
62731d4889d6502ff091ce490e109b9677a7c0228915bb0796466177c2e61eec
|
|
| MD5 |
af13964b9ace99bd589f56b8ba335ec1
|
|
| BLAKE2b-256 |
a3629baca742f3be9374495e0e5443d298fb73611ad970092c23db001064369f
|
File details
Details for the file hfmt_cli-0.1.1-py3-none-any.whl.
File metadata
- Download URL: hfmt_cli-0.1.1-py3-none-any.whl
- Upload date:
- Size: 6.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7c61c273dfe9622e59bf4aa9e683a42188c9289b13cb0031a7ca290979c38f08
|
|
| MD5 |
e195c1c371891c330d161c5ed8568af7
|
|
| BLAKE2b-256 |
8a0fab48e0379a9bd666744a50dcf3883e4bb68705970e015f0e7fe6f5d40f69
|