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

FlagRequiredDescription
--user <owner>RequiredGitHub user or organization to clone from. Interactive runs prompt when omitted.
--visibility <all|public|private>OptionalVisibility filter. Default: all. Invalid values fail.
--limit <number>OptionalMaximum repositories to list. Default: 100; must be at least 1.
--into <directory>OptionalTarget directory for cloned repositories. Default: the owner name.
--guidedOptionalInteractively configure command options before execution.

Prerequisites

  • git and gh must be installed
  • For private or all visibility, Git Wrangler GitHub auth must be configured with git-wrangler init, git-wrangler config set github.auth, or GIT_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 --into directory 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