The skeleton command

git teleport skeleton [--] <repo1> [<repo2> .. <repoN>]

Creates new git repositories that are compatible with the unpack command. The new repositories are created in the <repoN> directories on your local filesystem.

git-teleport can use any Git repository as a Receive Mirror so long as its filename or URL prefix is permitted. The skeleton command provides an additional layer of protection: it discourages users from modifying (i.e., by git push) the repo outside of git-teleport. Repositories created with skeleton:

  • Have core.sharedRepository set, which helps preserve access on shared filesystems.

  • Have a pre-receive hook that can prevent accidental pushes.

  • Have a special marker file which indicates to unpack that the repository is safe to use.

The skeleton command is safe to rerun on existing mirror repositories.

Limitations

  • Only use skeleton for creating mirrored repositories. skeleton must not be used to create regular, read/write repositories that contain original commits. Create these with git init instead.

  • githooks only run if permitted by safe.directory restrictions.

Required URL Prefix

git-teleport will only unpack into repository URLs which have a path component named "mirror" or "mirrors" exactly. For example,

git@mygitlab:mirrors/intranet/
https://mygitlab/mirror/extranet/
/net/share/git/mirror/public/

are all valid URL prefixes.

You should also create subdirectories, like intranet, to separate mirrors received from different sources.

The URL prefix is optional for repositories created with skeleton and shared on a local filesystem. The prefix is required for network protocols, like https.