Git Product home page Git Product logo

rapidrepopull's Introduction

RapidRepoPull

os rapidrepoinstallver Twitter CodeFactor Build Status

alt text

Created and Maintained by

  • Talal Balouch (Twitter @xtbalz)

Description

  • This program uses Python to clone/maintain multiple security related repos using threading and multiprocessing

Goal

  • The goal of this program is to quickly pull and install repos from its list

Use cases

  • Quickly install your favorite Security repos on a new system

  • Kick off multiple concurrent git clone tasks utilizing Python

  • Add/remove Security related Github repos to the default.xt list as needed in order to address indivudual use case/project needs

  • Clone repos to review offline while traveling without internet connectivity

Requirements

  • This program was tested with Python3 version 3.8.9 64-bit

  • Ensure the Python3 virtual environment package is installed (Ubuntu)

    sudo apt-get install python3-venv

  • Ensure git is installed (Ubuntu)

    sudo apt-get install git

Usage Option 1 Automatic (Docker)

This option does not allow a user to specify the number of threads or a text file including additional repos

  • Clone code repo

    git clone https://github.com/tbalz2319/RapidRepoPull.git

  • Change directory into RapidRepoPull

    cd RapidRepoPull

  • The script will run in a minimal Alpine Docker container (126 MB) and extract the dirs in the current working dir

    docker-compose up --build

Usage Option 2 Local Install

  • Clone code repo

    git clone https://github.com/tbalz2319/RapidRepoPull.git

  • Change directory into RapidRepoPull

    cd RapidRepoPull

  • Execute the script below

    ./install.sh

Usage Option 3 Manual

  • Clone code repo

    git clone https://github.com/tbalz2319/RapidRepoPull.git

  • Change directory into RapidRepoPull

    cd RapidRepoPull

  • Create a virtual Python3 environment to run this code

    python3 -m venv venv

  • Activate the virual enivornment

    source venv/bin/activate

  • Install requirements

    pip install -r requirements.txt

  • Run program

    python rapid.py

Usage Option 4 Custom

  • Clone code repo

    git clone https://github.com/tbalz2319/RapidRepoPull.git

  • Change directory into RapidRepoPull

    cd RapidRepoPull

  • Execute the script below

    ./option4.sh

  • The script will exit while leaving the program in a python virtual env indicated by (venv)

  • Use the help menu below to navigate options

    Usage: rapid.py [OPTIONS]

       Options:
       -v, --verbose      Will print verbose messages.
       -f, --file TEXT    Specify a text file with a list of user selected Github repos
       -t, --thread TEXT  Specify the number of CPU threads to use
       -u, --url TEXT     Specify a url to scrape containing Github repos to clone
       --help             Show this message and exit.```
    
    
  • Example specifying a custom text file with a list of repos and how many threads the script should use

  • The text file must reside in the same directory as rapid.py and can be called anything

  • The example file "bob.txt" is there to testing an example purposes

    python rapid.py -f bob.txt -t 25

  • The example below with scrape a url containing Github to clone and provide verbose output, utilizing 75 threads

    python rapid.py -v -u https://apsdehal.in/awesome-ctf -t 75

Update Program

  • Run the following script

    ./update.sh

Mass Update all existing repos

  • Run the command to maintain all existing repos by attempting to pull latest version

    ./update_repos.sh

To do

  • Add error handling

  • Clean up code

  • Implement new features to enhance functionality via cli

Contribute

  • The code for this project is constantly being cleaned up, refactored and refined, there are most likely lots of bugs that need to fixed and identified.

  • Any help with the project is greatly appreciated

  • Pull requests welcomed

rapidrepopull's People

Contributors

tbalz2319 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

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.