git-annex-p2p(1)

πŸ“¦
version 10.20261026 Β· 3 versions
, in alpine 3.24, arch rolling, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu resolute, ubuntu stonking

✨ 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 than tor, you need the helper program git-annex-p2p-<netname> installed first, fr fr. And after you run this command, you can run git annex remotedaemon to serve incoming connections from peers, and git-annex p2p --pair or git-annex p2p --gen-addresses to 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 to stdout. 🌈
⚠️ 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 --link or --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