A terminal-based Hacker News reader that displays stories in a beautiful table format.
Project description
HN UI
A terminal-based Hacker News reader that displays stories in a beautiful table format.
Features
- View top, new, best, ask, show, and job stories from Hacker News
- Customizable number of stories to display
- Start from any rank in the story list
- Rich terminal interface with colored output
- Rate-limited API calls to respect Hacker News API limits
- Concurrent fetching for improved performance
Installation
pip install -e .
Usage
# Show top 50 stories (default)
hnd
# Show top 10 stories
hnd -n 10
# Show new stories
hnd -m new
# Show stories starting from rank 20
hnd -s 20
# Show 5 ask stories starting from rank 10
hnd -m ask -s 10 -n 5
Command Line Options
-m, --mode: Story mode to display (choices: top, new, best, ask, show, job)-s, --start: Start from this rank article (1-based index, default: 1)-n, --num: Number of articles to display (default: 50)
Story Modes
- top: Top stories (up to 500)
- new: New stories (up to 500)
- best: Best stories (up to 500)
- ask: Ask HN stories (up to 200)
- show: Show HN stories (up to 200)
- job: Job stories (up to 200)
Requirements
- Python 3.12+
- requests
- rich
Development
This project uses uv for dependency management. To set up for development:
uv sync
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
hn_ui-0.1.0.tar.gz
(3.7 kB
view details)
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
hn_ui-0.1.0-py3-none-any.whl
(4.4 kB
view details)
File details
Details for the file hn_ui-0.1.0.tar.gz.
File metadata
- Download URL: hn_ui-0.1.0.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
382cc33f7cd7ebe17040943c79f4cdb275a9313036cecbf6e545dae331e74483
|
|
| MD5 |
2eeef846173197fac09c209c4589b2ad
|
|
| BLAKE2b-256 |
0229d0ea18810da529a1a97c238280541326e84832894d2b818d2e5fa73a9d1d
|
File details
Details for the file hn_ui-0.1.0-py3-none-any.whl.
File metadata
- Download URL: hn_ui-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c44b37907f79b9ec2959c20d6082c44d3301060ff19f00606efaebedda0605ea
|
|
| MD5 |
a401199d8e1028fd4219ed8c978c20f4
|
|
| BLAKE2b-256 |
6fcfca9e69612335a0a2bf059ddb93a9c77b579443d0b83f0b66f3f4c9e5c8a1
|