Giter Site home page Giter Site logo

wadder12 / reporipper Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 41 KB

RepoRipper - a script to download whatever repo of yours to a .txt file , so you can share it with AI Models!

License: MIT License

Python 100.00%
ai claude gemini-pro openai python scripts txt

reporipper's Introduction

RepoRipper

Caution

Disclaimer: This code is provided "as is" without any warranties, express or implied. The author is not responsible for any damages resulting from its use.

This repository contains a Python script, RepoRipper.py, downloads your whole git repo to a .txt file so you can share it with any AI model.

OpenAI | Claude | Gemini

MODEL WEBSITE
OpenAI 1 https://openai.com/chatgpt
Claude 2 https://claude.ai/
Gemini 3 dont know why their link so long

Important

Is this Legal? As to my research I believe this code is in the clear 4 5 6 7

Caution

Be aware that large repositories may encounter rate limits when using this script due to GitHub API restrictions. This is an inherent limitation and not a fault of the script itself.

Requirements:

  • Python 3
  • requests library
  • base64 library
  • dotenv library
  • tqdm library
  • colorama library

Setup:

  1. Create a .env file:

    • In the same directory as the script, create a file named .env.

    • Add the following line to the file, replacing the placeholder with your actual GitHub personal access token:

      GITHUB_TOKEN=your_github_token
      
  2. Install dependencies:

    • Open a terminal in the script's directory and run the following command:

      pip install requests base64 dotenv tqdm colorama

Usage:

  1. Run the script:

    • Execute the script using:

      python RepoRipper.py
  2. Enter repository URL:

    • When prompted, provide the URL of the GitHub repository you want to download from.
  3. Select exclusions (optional):

    • The script will display a list of file types and directories that can be excluded.
    • Enter the corresponding numbers separated by spaces to exclude specific items.
    • Press Enter to proceed without exclusions.
  4. Wait for download:

    • The script will fetch the files and save them to a single text file in the current directory or the specified SAVE_DIRECTORY in the .env file.

Customization:

  • You can modify the exclusion_list.txt file to add or remove file types and directories to be excluded by default.
  • You can set the SAVE_DIRECTORY environment variable in the .env file to specify where the downloaded text file should be saved.

Note

  • Make sure your GitHub personal access token` has the necessary permissions to access the repository.
  • The script will skip binary or non-UTF-8 files.
  • The script will overwrite any existing file with the same name in the save directory.

TODO

  • #1
  • Validate User Inputs
  • Handle API Rate Limiting
  • Cross-Platform Testing
  • Legal and Ethical Considerations
  • Enhance Binary File Handling

Footnotes

  1. here is the raw link lol https://openai.com/chatgpt

  2. here is the raw link lol https://claude.ai/

  3. here is the raw link lol https://gemini.google.com/?utm_source=google&utm_medium=cpc&utm_campaign=2024enUS_gemfeb&gad_source=1&gclid=CjwKCAjwh4-wBhB3EiwAeJsppOWzLIcw-EAxub7vOFjZb_hcQoMWw1sPL-BPdHTQ99DZnQtS5NzRnhoC41oQAvD_BwE

  4. Legal https://docs.github.com/en/site-policy/github-terms/github-community-guidelines

  5. Legal https://docs.github.com/en/site-policy/github-terms/github-open-source-applications-terms-and-conditions

  6. Legal https://docs.github.com/en/site-policy/github-terms/github-marketplace-developer-agreement

  7. Legal https://docs.github.com/en/site-policy/github-terms/github-terms-of-service

reporipper's People

Contributors

wadder12 avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

reporipper's Issues

Improve Error Handling

  • Add more comprehensive checks for response statuses from GitHub API.
  • Implement error handling for file operations (e.g., opening exclusion_list.txt).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.