Skip to content

Repository files navigation

DocMint

DocMint

Turn any GitHub repository into polished documentation — automatically.

License: MIT TypeScript Next.js


DocMint landing page

DocMint analyzes your GitHub repository — reading the actual source files, not just the metadata — and generates a complete, structured README in under 30 seconds. The result opens in a drag-and-drop block editor where you can reorder sections, edit inline, lock blocks you've written by hand, and export as Markdown or HTML.

Table of Contents

How it works

  1. Paste a GitHub URL — any public repository works without authentication.
  2. DocMint reads the codebase — it fetches the file tree and parses package.json, Dockerfile, .env.example, GitHub Actions workflows, and other config files to build an accurate picture of the project.
  3. A README is generated — structured into sections (overview, installation, usage, tech stack, API routes, environment variables, contributing) based on what the repo actually contains.
  4. Edit in the block editor — drag sections to reorder, edit content inline, hide sections you don't need, or lock blocks to protect manual edits from being overwritten on regeneration.
  5. Export — download as README.md, export as HTML, or copy to clipboard.

DocMint editor

Getting Started

Prerequisites: Node.js 18+

git clone https://github.com/kcooperdev/docmint
cd docmint
npm install

Copy the environment file:

cp .env.local.example .env.local

Start the development server:

npm run dev

Open http://localhost:3000.

Configuration

Variable Description Required
GITHUB_TOKEN Personal access token for higher GitHub API rate limits. Without this, you're limited to 60 unauthenticated requests per hour. Create one at github.com/settings/tokens with public_repo scope. No
OPENAI_API_KEY Enables AI-enhanced prose for the overview and features sections. Without this, DocMint uses structured template generation, which is still accurate since it pulls real data from the repo. No

Tech Stack

  • Next.js 15 — App Router, API routes, and server components
  • TypeScript — end-to-end type safety across the codebase
  • Tailwind CSS — utility-first styling
  • Framer Motion — scroll-driven parallax and page transitions
  • @dnd-kit — accessible drag-and-drop for the block editor
  • react-markdown — live markdown rendering in the preview pane

Project Structure

src/
├── app/
│   ├── api/
│   │   ├── analyze-repo/    # Fetches and parses the GitHub repo
│   │   └── generate-readme/ # Assembles README sections from parsed data
│   ├── generate/            # Editor page
│   └── page.tsx             # Landing page
├── components/
│   ├── editor/              # Block editor and markdown preview
│   └── landing/             # Landing page sections
└── lib/
    ├── github.ts            # GitHub API client and repo analysis
    ├── readme-generator.ts  # Section templates and markdown assembly
    └── openai.ts            # Optional AI enhancement layer

Contributing

Pull requests are welcome. For significant changes, open an issue first to discuss what you'd like to change.

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/your-feature
  3. Commit your changes and open a pull request

License

Distributed under the MIT License.

About

create better readme with docmint

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages