Skip to content

PatrickFeiring/pg-docs

Repository files navigation

pg-docs

Build a documentation website based on your databases comments and Markdown.

The project is inspired by two blog posts on the Mercury engineering blog, 8 Lints for your Postgres schema and Documenting your database schema, highlighting the importance of documenting your data models and making them accessible to technical and non-technical people in your organization alike.

pg-docs builds on this idea, also taking inspiration from rustdoc, making it easy to produce Markdown based documentation while allowing you to link between objects in your database, allowing users to easily jump between related concepts.

This is all based on Postgres' ability to add comments to objects in your database

COMMENT ON TABLE member IS 'Table documentation';

something akin to docstrings in coding languages. pg-docs reads these comments and builds a static website you can easily host and integrate in your CI pipelines.

Getting started

The project builds against an instance of your database, using postgres environment variables to connect to a live instance of your database. You can then run

pnpm run dev

Writing documentation

In overview a summary

COMMENT ON 

Examples

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published