Skip to main content

Prerequisites

Before installing repo2pdf, ensure you have the following installed on your system:
  • Node.js version 18.0.0 or higher
  • git (required only for cloning remote repositories)
You can check your Node.js version by running node --version in your terminal

Installation methods

Verify installation

To verify that repo2pdf is working correctly, run it with NPX:
npx repo2pdf
You should see the repo2pdf welcome banner:
██████╗ ███████╗██████╗  ██████╗         ██████╗         ██████╗ ██████╗ ███████╗
██╔══██╗██╔════╝██╔══██╗██╔═══██╗        ╚════██╗        ██╔══██╗██╔══██╗██╔════╝
██████╔╝█████╗  ██████╔╝██║   ██║         █████╔╝        ██████╔╝██║  ██║█████╗
██╔══██╗██╔══╝  ██╔═══╝ ██║   ██║        ██╔═══╝         ██╔═══╝ ██║  ██║██╔══╝
██║  ██║███████╗██║     ╚██████╔╝        ███████╗        ██║     ██████╔╝██║
╚═╝  ╚═╝╚══════╝╚═╝      ╚═════╝         ╚══════╝        ╚═╝     ╚═════╝ ╚═╝

Welcome to Repo-to-PDF! Let's get started...

Troubleshooting

If you see “command not found” when running npx repo2pdf, ensure:
  • Node.js and npm are properly installed
  • Your npm installation is in your system PATH
  • You have an active internet connection (for NPX to download packages)
This usually indicates a network or permissions issue:
# Try clearing npm cache
npm cache clean --force

# Then retry
npx repo2pdf
If using global installation, you may need to use sudo on macOS/Linux:
sudo npm install -g repo2pdf
repo2pdf requires Node.js 18 or higher. Update Node.js:
  • Visit nodejs.org to download the latest LTS version
  • Or use a version manager like nvm:
    nvm install 18
    nvm use 18
    

Next steps