Experimental project

This is a sandbox project, which contains experimental code for developer use only.

Drupal Git Cache creates a cache of git objects that can be used when checking out projects from git.drupal.org. Objects already in the cache do not need to be downloaded again allowing for speedier clones.

For example, if Drupal is already in the cache (or most of the commits) you can use the reference option like:

git clone --reference ~/gitcaches/drupal git://git.drupal.org/project/drupal.git

All the objects that are in the reference will be fetched from there rather than downloaded. Fetching locally is much faster than downloading them.

Script Usage

There are three options within this script being to initialize repos initially, add new repos, and update all repos.

Initialize:

./drupal-git-cache.sh init

Add a new repo:

./drupal-git-cache.sh add project_name

Update repos:

./drupal-git-cache.sh update

Configure Scripts

Before you use the scripts there are a couple of options to configure. Open up drupal-git-cache.sh and set the following variables:

  1. REPO: The location to keep the git cache.
  2. PROJECTS: The initial list of projects to download and cache.

This was inspired by Randy Fays scripts at http://randyfay.com/node/93

Project information

  • Created by mfer on , updated