git-annex-p2p(1)
β¨ git-annex-p2p β¨
okay bestie, welcome to the git-annex-p2p(1) page from the General Commands Manual β this is the one that sets up peer-2-peer links between your repos π¦
NAME
git-annex-p2p β configure peer-2-peer links between repositories π
SYNOPSIS
git annex p2p [options]
DESCRIPTION
So like. This command? It links git-annex repositories over peer-2-peer networks. Iconic behaviour honestly.
git-annex ships with built-in support for using Tor hidden services as a P2P network. (β οΈ caveat: this needs Tor to actually be installed. no Tor, no vibes.)
git-annex can also support other P2P networks, using a helper program that you install yourself. These helper programs have names of the form git-annex-p2p-<netname>. Want the deets? They live at https://git-annex.branchable.com/special_remotes/p2p/ π«Ά
OPTIONS β¨
--enable <netname>β turns on using the P2P network with that specific name. For networks other thantor, you need the helper programgit-annex-p2p-<netname>installed first, fr fr. And after you run this command, you can rungit annex remotedaemonto serve incoming connections from peers, andgit-annex p2p --pairorgit-annex p2p --gen-addressesto give other users access to your repository via the P2P network. it's giving full ecosystem π--pairβ run this in two repositories to pair them together over the P2P network π
This prints out a code phrase, like "3-mango-elephant", and then prompts you to enter the code phrase from the other repository. (yes the example is literally a mango and an elephant. slay.)
Once code phrases have been exchanged, the two repositories will be paired. A git remote gets created for the other repository, with a name like "peer1".
This uses [Magic Wormhole](https://github.com/warner/magic-wormhole) to verify the code phrases and securely communicate the P2P addresses of the repositories, so you will need it installed on both computers that are being paired.
history lesson, bestie: this feature was present in a broken form in git-annex versions before version 6.20180705. Make sure that a new enough git-annex is installed on both computers that are being paired. don't be out here pairing with ancient git-annex π
--gen-addressesβ generates addresses that can be used to access this git-annex repository over the available P2P networks. The address or addresses is output tostdout. π
β οΈ heads up: note that anyone who knows these addresses can access your repository over the P2P networks. so like, be mindful who you hand them to π
This can be run repeatedly, in order to give different addresses out to different people. different address for every bestie, we love to see it π
--linkβ sets up a git remote that is accessed over a P2P network.
This will prompt for an address to be entered; you should paste in the address that was generated by --gen-addresses in the remote repository. copy-paste is a valid love language π
Defaults to making the git remote be named "peer1", "peer2", etc. This can be overridden with the --name option.
--nameβ specify a name to use when setting up a git remote with--linkor--pair. name your children (remotes) whatever you want π
Also the git-annex-common-options(1) can be used. don't forget the classics β¨
SEE ALSO π
AUTHOR πΈ
Joey Hess <id@joeyh.name>
and that's the whole page, bestie π§π« this was the git-annex-p2p(1) manual page from the General Commands Manual. go forth and pair your repositories, no cap π
π«Ά
π¦ where this page comes from
- alpine 3.24: git-annex-doc 10.20261026-r0 Β· AGPL-3.0-or-later
- arch rolling: git-annex 10.20261026-2 Β· AGPL-3.0-only
- fedora 43: git-annex 10.20250929-5.fc43 Β· AGPL-3.0-or-later
- fedora 44: git-annex 10.20260115-1.fc44 Β· AGPL-3.0-or-later
- nixos 26.05: git-annex 10.20260421
- nixpkgs unstable: git-annex 10.20260421
- opensuse-leap 16.0: git-annex 10.20250828-bp160.1.1 Β· AGPL-3.0-or-later AND GPL-3.0-or-later AND BSD-2-Clause AND MIT AND GPL-2.0-only
- opensuse-leap 16.0: git-annex 10.20250828-bp160.1.1 Β· AGPL-3.0-or-later AND GPL-3.0-or-later AND BSD-2-Clause AND MIT AND GPL-2.0-only
- opensuse-leap 16.0: git-annex 10.20250828-bp160.1.1 Β· AGPL-3.0-or-later AND GPL-3.0-or-later AND BSD-2-Clause AND MIT AND GPL-2.0-only
- ubuntu resolute: git-annex 10.20251029-1ubuntu1 Β· AGPL-3.0-or-later
- ubuntu stonking: git-annex 10.20251029-1ubuntu1 Β· AGPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms