a command-line tool that transforms a Git repository into a minimal format for ChatGPT queries.
- Excludes LICENSE and files in the .gitignore
- Can exclude specific files or directories
- Reduces whitespace for files with non-significant whitespace
- Optional preamble file for adding custom instructions
- Uses the R-word (R*st)
gprepo [FLAGS] [OPTIONS]
-h, --help
: Prints help information-V, --version
: Prints version information
-i, --ignore <IGNORE_PATH>
: File paths to ignore (can be specified multiple times)-o, --output <OUTPUT_PATH>
: Output file path (default: stdout)-p, --preamble <PREAMBLE_PATH>
: Optional path to the preamble file-r, --repo-path <REPO_PATH>
: Path to the repository
Translate a Git repository and output the result to a file:
gprepo -r /path/to/repo -o output.txt
Exclude specific files or directories:
gprepo -i "target/" -i "node_modules/"
Add a custom preamble file:
gprepo -p my_preamble.txt
cargo install --git https://github.com/jtrv/gprepo
This project is licensed under the MIT License.