clone
Clones multiple GitHub repositories for a user or organization.
Usage
git-wrangler clone --user <owner> [--visibility <all|public|private>] [--limit <number>] [--into <directory>] [--guided]
What it does
Lists repositories for a GitHub user or organization with gh repo list, then clones each repository with gh repo clone. Existing destination directories are successful skips, so the command is safe to rerun.
Private and all visibility runs require Git Wrangler GitHub auth. Public-only cloning can run without stored Git Wrangler auth if gh can list the public repositories.
Options
| Flag | Required | Description |
|---|---|---|
--user <owner> | Required | GitHub user or organization to clone from. Interactive runs prompt when omitted. |
--visibility <all|public|private> | Optional | Visibility filter. Default: all. Invalid values fail. |
--limit <number> | Optional | Maximum repositories to list. Default: 100; must be at least 1. |
--into <directory> | Optional | Target directory for cloned repositories. Default: the owner name. |
--guided | Optional | Interactively configure command options before execution. |
Prerequisites
gitandghmust be installed- For
privateorallvisibility, Git Wrangler GitHub auth must be configured withgit-wrangler init,git-wrangler config set github.auth, orGIT_WRANGLER_GITHUB_TOKEN
Examples
# Clone all public repos for an organization into ./repos
git-wrangler clone --user my-org --visibility public --into ./repos
# Clone up to 10 repos into a directory named after the user
git-wrangler clone --user my-org --limit 10
# Clone all repos (public + private; requires Git Wrangler auth)
git-wrangler clone --user my-org --visibility all
Notes
- Existing directories are skipped automatically (the command is idempotent)
- The
--intodirectory is created if it does not exist - If secure keyring storage is unavailable, authenticated runs direct you to
GIT_WRANGLER_GITHUB_TOKEN; public-only cloning can continue without Git Wrangler auth