Git Clients

ghq – organise local clones of remote repositories

ghq is a command-line tool for organising local clones of remote repositories.

It stores repositories under a consistent root directory, by default ~/ghq, using a host/user/project directory layout. This makes it easier to keep many repositories tidy, locate checked-out projects, and avoid scattering clones across unrelated directories.

The tool can clone repositories from compact names or full URLs, list existing local repositories, remove managed clones, create new repositories, and migrate existing checkouts into its managed directory structure. It’s particularly useful for developers who regularly work across multiple GitHub projects, self-hosted repositories, or mixed source control environments.

This is free and open source software.

Key Features

  • Clones remote repositories into a predictable host/user/project directory hierarchy.
  • Lists managed local repositories, with optional query matching and full-path output.
  • Updates existing clones when requested instead of duplicating repositories.
  • Supports shallow, bare, branch-specific, recursive, and partial clone options for Git repositories.
  • Supports multiple ghq root directories, with one primary root used for new clones.
  • Can remove managed local repositories, with a dry-run option for safety.
  • Migrates existing repository directories into the ghq-managed layout.
  • Uses git-config variables for configuration, including root paths, default host, and VCS settings.
  • Cross-platform support – runs under Linux, macOS, and Windows.

Website: github.com/x-motemen/ghq
Support:
Developer: x-motemen
License: MIT License

ghq commands

ghq is written in Go. Learn Go with our recommended free books and free tutorials.


Related Software

Git Storage and Security Tools
git-lfsGit extension for versioning large files
JujutsuPowerful version control system for software projects
git-bugDistributed offline-first bug tracker
DashRich terminal UI for GitHub
git-secretsPrevent adding secrets into git repositories
CommitizenCreate well-structured Git commit messages
git-repairRepair various forms of damage to git repositories
git-secretBash tool which stores private data inside a git repo
git-annexManage files with git without checking the file contents into git
gitmoji-cliUse gitmojis in Git commit messages
ghqOrganise local clones of remote repositories
git-cryptTransparent file encryption in git
gitaManage multiple git repos
git-chglogCHANGELOG generator implemented in Go
cz-gitCommitizen adapter and command-line tool
gitpaneMulti-repo Git workspace dashboard
git-trimKeep Git working directories clear of stale local branches
gfoldKeep track of multiple Git repositories
GardenCommand runner and multi-repo Git configuration tool
maniManage collections of Git repositories
GitSocialGit-native cross-forge collaboration
git-freshRefresh Git working copies from the terminal
Forge SparksGet Git forges notifications
gohomeGit standup and activity reporting CLI
git-appraiseDistributed code review system for Git repositories

Read our verdict in the software roundup.


Best Free and Open Source Software Explore our carefully curated directory of recommended free and open source software, covering every major software category.

The directory forms part of our extensive collection of articles for Linux enthusiasts. It includes hundreds of detailed reviews, together with free and open source alternatives to proprietary software from companies such as Google, Microsoft, Apple, Adobe, IBM, Cisco, Oracle, and Autodesk.

LinuxLinks also covers interesting projects worth exploring, Linux-compatible hardware, free programming books and tutorials, and much more.

Know a useful free and open source Linux application that we haven’t covered? Tell us about it using our submission form.
Subscribe

Please read our Comment Policy before commenting.

Notify of
guest
0 Comments
Oldest
Newest Most Voted