Crates.io | gpt-feeder |
lib.rs | gpt-feeder |
version | 2.0.3 |
source | src |
created_at | 2023-03-25 18:05:57.399793 |
updated_at | 2024-07-02 06:40:04.559624 |
description | A command-line application that scans the entire codebase, and produces one string consisting of all filenames and file contents that you want included. |
homepage | |
repository | https://github.com/magnusrodseth/gpt-feeder/tree/main |
max_upload_size | |
id | 820425 |
size | 168,545 |
GPT models today have a high token capability, allowing for use cases like long form content creation, extended conversations, and document search and analysis.
GPT Feeder is a command-line application that scans the entire codebase, and produces one string consisting of all filenames and file contents you want to be included. This string can then be fed into ChatGPT, and the model can generate code based on the context of your code base.
Ensure you have cargo
installed. Then, run the following command:
# Install the application
cargo install gpt-feeder
Ensure you have gpt-feeder
installed. Add all ignored file and directory patterns to .feedignore
, just like you would with a .gitignore
. Then, run the following commands:
# Navigate to the directory you want to scan
cd <directory>
# Run the application with the file extensions you want included
gpt-feeder --include *.rs *.md
# If you want to output the result to a file, use the `--out` flag
gpt-feeder --include *.rs *.md --out output.txt
# Print help
gpt-feeder --help
✂️ Note that gpt-feeder
automatically copies the content to your clipboard.
You can now paste this string into ChatGPT, and generate code based on the context of your code base. 🚀
GPT Feeder relies on your shell to expand glob patterns. This is done in order to allow your shell to give you autocomplete suggestions on the patterns, in addition to making it easier for the program to handle an arbitrary amount of glob patterns whilst still being user-friendly.
For more information on how to contribute and run the application, see CONTRIBUTING.md.