multiclone

command module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 7, 2017 License: MIT Imports: 13 Imported by: 0

README

Multiclone

Clone all the forks of a repository, or all the repos of a GitHub Classroom assignment.

This is useful for collecting and reviewing assignments and student projects.

Features:

  • Written in Golang for easier distribution. (I got tired juggling of juggling Anaconda / virtualenv between various classroom and tool environments.)
  • Automatic repo discovery. Knows about “students fork” and “GitHub Classroom” conventions.
  • Repos are cloned in parallel.
  • Create a myrepos .mrconfig file.

Usage

multiclone https://github.com/owner/repo
multiclone owner/repo

Clone forks of owner/repo into the current directory.

multiclone repos.txt

repos.txt is a file with one repo name per line.

GitHub Classroom
multiclone https://github.com/owner/repo --classroom
multiclone org/repo --classroom

Clone org's repos named repo-* into the current directory.

This is intended for use with repos created via GitHub Classroom.

Options
multiclone --dir path/to/dir owner/repo

Clone into subdirectories of path/to/dir, instead of the current directory.

multiclone owner/repo --dry-run

See the git commands that would be run, without actually running them.

multiclone --help

Lists additional options.

Install

  1. Install go (1) via Homebrew: brew install go; or (2) download.
  2. go install github.com/osteele/multiclone
  3. Create a GitHub personal access token for the command line
  4. Set GITHUB_TOKEN to this value: export GITHUB_TOKEN=…

Alternatives

These GitHub Education Community forum threads discuss a variety of alternatives (including one I wrote before I wrote this):

myrepos automates parallel management of a set of repos. It doesn't create the initial repo set, which is that this tool does.

License

MIT

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL