---
name: "git-grab"
section: "1"
platform: "linux"
package: "git-grab"
version: "4.0.1-3"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/git-grab"
---

# git-grab(1)

clone git repositories to a standard location

## NAME

**git-grab** – clone git repositories to a standard location

## SYNOPSIS

**git-grab** \[**-chnpV**\] *URL* ... \[*--* *git* *arguments* ...\]

## DESCRIPTION

The **git-grab** utility clones git repositories to a standard location, organised by domain name and path. Pass one or more *URL* to clone. Arguments for git may be supplied after *--*.

The following options are available:

- **-c,** **--clipboard**

  Paste a URL to clone from the clipboard.

- **--home**

  The directory to use as "grab home", where the URLs will be cloned into. Overrides the GRAB\_HOME environment variable if set.

- **-p,** **--copy-path**

  Copy the local destination path to clipboard after cloning. If more than one URL is supplied the path of the last one is copied.

- **-n,** **--dry-run**

  Don't clone repositories, but print what would be done.

- **-h,** **--help**

  Display a help message and exit.

- **-V,** **--version**

  Display version information and exit.

## ENVIRONMENT

- GRAB\_HOME

  The base directory to clone into. If the variable GRAB\_HOME is not set, *~/src* is used.

- GRAB\_COPY\_PATH

  If set, copy the local destination path to the clipboard after cloning. (equivalent to \[*--copy-path*\])

## EXIT STATUS

The **git-grab** utility exits 0 on success, and \>0 if an error occurs.

## SEE ALSO

[git-clone(1)](/git-clone/1.md)

## HISTORY

The **git-grab** utility is inspired by grab by Jeff Hodges. This implementation was written from scratch by Wesley Moore.
