CLI tool that scaffolds README.md from project layout and manifest files (offline, no API)
Project description
README Auto-Generator
Point it at any codebase. Get a structured README.md from layout and manifest files — no API keys, no network calls.
Table of Contents
- Overview
- Features
- Tech Stack
- Project Structure
- Prerequisites
- Installation
- Configuration
- Usage
- How It Works
- Contributing
- License
Overview
README Auto-Generator is a CLI tool that scans a local project directory, collects manifest files (for example package.json, pyproject.toml, requirements.txt), builds a directory tree, detects languages from extensions, and assembles a README template you can refine. It does not call external AI services.
See PROJECT.md for the full project document, design decisions, and learning goals.
Features
- Works offline — standard library only at runtime
- Scans common stacks: Python, JavaScript/TypeScript, Node, Rust, Go, and more (via extensions and manifests)
- Reads high-value manifests automatically (
package.json,requirements.txt,Dockerfile,Makefile, etc.) - Builds a directory tree and samples entry-point source files (size-capped)
- Respects ignore rules: skips
node_modules,__pycache__,.git, binaries, and images - Dry-run mode to preview output without writing to disk
Tech Stack
| Component | Technology |
|---|---|
| Language | Python 3.9+ |
| CLI | argparse (stdlib) |
| File I/O | pathlib (stdlib) |
Project Structure
readme-auto-generator/
├── main.py Legacy entry point (if present)
├── requirements.txt Documents stdlib-only runtime
├── setup.py
├── pyproject.toml
├── .gitignore
├── PROJECT.md Full project document
├── README.md This file
├── readme_generator/
│ ├── __init__.py
│ ├── analyzer.py Codebase scanner
│ ├── generator.py README assembly from context
│ └── cli.py Command-line interface
└── examples/
└── sample_output.md Example generated README
Prerequisites
- Python 3.9 or higher
Installation
# 1. Clone the repo
git clone https://github.com/yourname/readme-auto-generator.git
cd readme-auto-generator
# 2. Create and activate a virtual environment (recommended)
python -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
# 3. Install as a CLI tool
pip install -e .
Configuration
No API keys or environment variables are required. Optional templates like .env.example are detected for the generated Configuration section when present in the project you scan.
Usage
Install exposes the readme-gen command (console script).
Basic — generate README for a project
readme-gen /path/to/your/project
This writes README.md into the target project directory (unless it exists — you will be prompted).
Specify a custom output path
readme-gen /path/to/your/project --output /path/to/custom/README.md
Preview without writing to disk
readme-gen /path/to/your/project --dry-run
Overwrite an existing README without prompting
readme-gen /path/to/your/project --overwrite
Run as a module
python -m readme_generator /path/to/your/project --help
Options
usage: readme-gen [-h] [--output OUTPUT] [--overwrite] [--dry-run] [--version]
project_path
How It Works
-
Analyze —
analyzer.pywalks the project directory, builds a directory tree, reads manifest files and key source files, and detects languages from file extensions. -
Generate —
generator.pyderives title, description, install hints, and tables from that context and emits Markdown sections (overview, tech stack, structure, usage stubs, manifest excerpts). -
Output — The CLI writes the Markdown to disk or prints it when
--dry-runis set.
Contributing
- Fork the repository
- Create a feature branch:
git checkout -b feature/my-feature - Commit your changes:
git commit -m 'Add my feature' - Push:
git push origin feature/my-feature - Open a Pull Request
License
MIT License. See LICENSE for details.
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 readme_auto_generator-2.0.0.tar.gz.
File metadata
- Download URL: readme_auto_generator-2.0.0.tar.gz
- Upload date:
- Size: 11.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
492efad3896cc6b8b507e91f67038fd729f2b726603a22b418f4951886482e9a
|
|
| MD5 |
b076da52cdd222cba7c5efea293fd43e
|
|
| BLAKE2b-256 |
fd87f681ce8cc709cd7b196f99baa32e09a17155390b1ab9531244d048f66a58
|
File details
Details for the file readme_auto_generator-2.0.0-py3-none-any.whl.
File metadata
- Download URL: readme_auto_generator-2.0.0-py3-none-any.whl
- Upload date:
- Size: 13.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
25c4e7f1dea9aade550b41e546b6e037ffe1367b031f7bf6b91c4d9caabddb4c
|
|
| MD5 |
8f7cd2e706cb1250c5ba455e523eb129
|
|
| BLAKE2b-256 |
766b52f6ad14571a8a0c6556443826a1a4e652fe921d8b68c00e2bf3c72113d9
|