Skip to main content

📄 project2pdf

Convert project structures into a single PDF. Perfect for providing context to an LLM (Large Language Model) about a specific project.

🚀 Features

Automatically detects projects in the root directory
Generates a structured PDF with directory trees and code snippets
Supports multiple file types (.py, .ipynb, .tsx, .js, Dockerfile, .env, .md, .gitignore)
No manual input needed – just run and get your documentation

📦 Installation

Install project2pdf from PyPI:

pip install project2pdf

🛠 Usage

Simply run the command inside your project directory:

project2pdf

This will:

  • Detect all project folders in the root directory
  • Generate a structured PDF for each project
  • Save the output in the root as project_name_documentation.pdf

📝 Example Output

After running project2pdf, you will find a PDF file like:

📂 my_project_documentation.pdf

🔧 Configuration

No additional configuration is needed. The script will:

  • Include the first two levels of the directory structure
  • Extract relevant code from supported files
  • Format everything in a clean, readable PDF

👨‍💻 Supported File Types

The tool processes and includes the following file types:

  • .py, .ipynb → Python scripts & Jupyter Notebooks
  • .tsx, .js → TypeScript/JavaScript files
  • Dockerfile, .env, .gitignore → Project metadata
  • .md → Markdown documentation

📌 Use Cases

🔹 Quickly onboard new developers to a project
🔹 Document your project before sharing it with an LLM
🔹 Organize and archive project structures

💡 Example

If your project structure is:

my_project/
│── src/
│   ├── main.py
│   ├── utils.py
│── README.md
│── requirements.txt
│── .gitignore

project2pdf will generate my_project_documentation.pdf with:

  1. Project structure (tree -L 2 output)
  2. Code snippets from main.py, utils.py, etc.
  3. Metadata from .gitignore, requirements.txt, etc.

🔥 Why Use This?

  • Automates project documentation 📑
  • Saves time onboarding new team members
  • Enhances LLMs' understanding of project context 🤖

🌍 License

MIT License. Free to use and modify!

📬 Feedback & Contributions

Have ideas or found a bug? Open an issue or contribute on GitHub!

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

project2pdf-0.3.6.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

project2pdf-0.3.6-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

Details for the file project2pdf-0.3.6.tar.gz.

File metadata

  • Download URL: project2pdf-0.3.6.tar.gz
  • Upload date:
  • Size: 6.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for project2pdf-0.3.6.tar.gz
Algorithm Hash digest
SHA256 76ac562aeb853d0a3fd34a8109b560641ec2a15aad71b37bd71b586226fb3794
MD5 ca87943e14f3f601eff31becaf0b9d74
BLAKE2b-256 1cf9dba2b860397f8d3c001605184b19945c3a0fb0e126cbbb253cc5b9f55aab

See more details on using hashes here.

File details

Details for the file project2pdf-0.3.6-py3-none-any.whl.

File metadata

  • Download URL: project2pdf-0.3.6-py3-none-any.whl
  • Upload date:
  • Size: 7.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for project2pdf-0.3.6-py3-none-any.whl
Algorithm Hash digest
SHA256 09562dac6132424904c5b4fe89b7a1b14826e4660a8a47b4b04cbfd00032fc33
MD5 3d61633bc791449345d3cad2177e40e4
BLAKE2b-256 fb5dff3232e3eabadc417ee0cbc2c1666039a8e348ee2cc4b6253cebf682c045

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.3.6 This release

2 files

0.3.5

2 files

0.3.4

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

0.2.9

2 files

0.2.6

2 files

0.2.4

2 files

0.2.3

2 files

0.2.1

2 files

0.2.0

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page