Skip to main content

cross-platform git utilities for managing a large number of git repositories quickly

Project description

Build Status Coverage Status Build status pypi versions pypi format PyPi Download stats

Git Utilities

Platform-independent (Linux/Mac/Windows) Git utilities, useful for managing large (100+) numbers of Git repos. I use command-line git because PyGit also requires command-line Git installed, and I don't need the advanced functionality.

A very important feature in

ListAllGithubRepos

is showing which forks of your repos have had changes "ahead of" your code. This shows your code is being improved, even if the forked repo didn't make a pull request. I don't know of any other easy way out there to find this.

Install

Install Git in a way accessible from the command line line

  • Mac: brew install git
  • Linux: apt install git
  • Windows: command line Git.
  • BSD: pkg install git
python -m pip install -e . 

Usage

I didn't know of any other easy ways to do these Git tasks:

  • gitbranch Tells of any non-master branches under directory ~/code
  • git_filemode_windows Sets all git repos to don't care permissions under directory ~/code
  • gitemail list all contributor email addresses. Optionally, amend email addresses for prior Git commits

GitHub

ListAllGithubRepos
Gives stats on GitHub repos for a particular user. It requires extra prereqs via:

pip install -e .[github]

Sync large number of git repos

These assume numerous subdirectories under ~/code or c:\code. They work very quickly for large numbers (100+) repos

  • gtps check if any repos have pending changes
  • gtpl Git pulls all repos
  • gtft Git fetches all repos

You can place an empty file .nogit in a subdirectory to skip pull or push.

Preview all changed Jekyll files

This is for a website made using Jekyll:

ActOnChanged -j

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gitutils-1.1.4.tar.gz (6.9 kB view details)

Uploaded Source

File details

Details for the file gitutils-1.1.4.tar.gz.

File metadata

  • Download URL: gitutils-1.1.4.tar.gz
  • Upload date:
  • Size: 6.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.2.0 requests-toolbelt/0.8.0 tqdm/4.23.3 CPython/3.7.0

File hashes

Hashes for gitutils-1.1.4.tar.gz
Algorithm Hash digest
SHA256 cef0c0d3a7423519dd3d5ae74a53fbe0e91c109710f29386981f22b5ba6c337e
MD5 4c6ce503a4f7fe7adee6e69e28ce039d
BLAKE2b-256 d72d0cb85bce827a25241f3aa19f08b4ed903c91fd1939e3e9b0616b2b7eae0a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page