Skip to main content

clone all group projects from gitlab

Project description

Git Clone Group (gcg)

A command-line tool to clone or update all projects from a GitLab group and its subgroups.

Features

  • Clone/update all repositories in a GitLab group and its subgroups
  • Specify branch to clone/pull
  • Parallel processing with progress bars
  • Smart retry mechanism
  • Empty repository detection
  • Detailed statistics

Installation

You can install git-clone-group using pip:

pip install git-clone-group

Usage

Basic usage:

gcg -g GITLAB_ADDR -t TOKEN -i GROUP_ID [-d DEST_DIR] [-b BRANCH]

Show help:

gcg -h

Examples:

# Clone all projects from group ID 123 to current directory
gcg -g gitlab.com -t glpat-xxxxxxxxxxxx -i 123

# Clone to a specific directory
gcg -g gitlab.com -t glpat-xxxxxxxxxxxx -i 123 -d /path/to/repos

# Clone specific branch from private GitLab instance
gcg -g git.company.com -t glpat-xxxxxxxxxxxx -i 456 -d ./projects -b develop

# Clone default branches
gcg -g gitlab.com -t glpat-xxxxxxxxxxxx -i 123 -d ./repos

Getting a GitLab Access Token

  1. Log in to your GitLab instance
  2. Go to Settings > Access Tokens
  3. Create a new personal access token with api scope
  4. Copy the token and use it with the --token argument

Getting a Group ID

You can find the group ID in GitLab:

  1. Go to your group's page
  2. The group ID is shown in the group information panel
  3. Or look at the URL: https://gitlab.com/groups/your-group-name - the group ID will be visible in the group details

Notes

  • The tool will automatically handle nested subgroups
  • For existing repositories, it will perform a git pull
  • Progress bars show real-time cloning/pulling status
  • Both HTTP and SSH URLs are supported (SSH recommended)

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

git_clone_group-1.1.2.tar.gz (9.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

git_clone_group-1.1.2-py3-none-any.whl (8.3 kB view details)

Uploaded Python 3

File details

Details for the file git_clone_group-1.1.2.tar.gz.

File metadata

  • Download URL: git_clone_group-1.1.2.tar.gz
  • Upload date:
  • Size: 9.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for git_clone_group-1.1.2.tar.gz
Algorithm Hash digest
SHA256 d46a9e496b8d230d7b9940dd8bba24320921234c112c39871c3e575a59cd17a0
MD5 f98331e84540d3585cd030bfcbc82d91
BLAKE2b-256 0b90f1ffaac223a8d97f8513ec1bdfdfaf39e2156b50510b74e75d9a15f2e051

See more details on using hashes here.

File details

Details for the file git_clone_group-1.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for git_clone_group-1.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 dc1e435a25805055ead2ce76c2c5b27637092e0e53f893d9ac1c8eae51185056
MD5 20c4bee1718bd6683ed44893acdcff5a
BLAKE2b-256 0ace130940e9d97c77c3c79784c13e4c5e44556277c99c0608f4bf5936fef884

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