Commit graph

44686 commits

Author SHA1 Message Date
Joey Hess
8d58a23548
add git for-each-ref binding
Sponsored-by: Luke T. Shumaker on Patreon
2024-05-07 14:22:04 -04:00
Joey Hess
c7731cdbd9
add Backend.GitRemoteAnnex
Making GITBUNDLE be in the backend list allows those keys to be
hashed to verify, both when git-remote-annex downloads them, and by other
transfers and by git fsck.

GITMANIFEST is not in the backend list, because those keys will never be
stored in .git/annex/objects and can't be verified in any case.

This does mean that git-annex version will include GITBUNDLE in the list
of backends.

Also documented these in backends.mdwn

Sponsored-by: Kevin Mueller on Patreon
2024-05-07 13:54:08 -04:00
Joey Hess
483887591d
working toward git-remote-annex using a special remote
Not quite there yet.

Also, changed the format of GITBUNDLE keys to use only one '-'
after the UUID. A sha256 does not contain that character, so can just
split at the last one.

Amusingly, the sha256 will probably not actually be verified. A git
bundle contains its own checksums that git uses to verify it. And if
someone wanted to replace the content of a GITBUNDLE object, they
could just edit the manifest to use a new one whose sha256 does verify.

Sponsored-by: Nicholas Golder-Manning
2024-05-06 16:28:04 -04:00
Joey Hess
f4ba6e0c1e
add annex: url parser
Changed the format of the url to use annex: rather than annex::

The reason is that in the future, might want to support an url that
includes an uriAuthority part, eg:

annex://foo@example.com:42/358ff77e-0bc3-11ef-bc49-872e6695c0e3?type=directory&encryption=none&directory=/mnt/foo/"

To parse that foo@example.com:42 as an uriAuthority it needs to start with
annex: rather than annex::

That would also need something to be done with uriAuthority, and also
the uriPath (the UUID) is prefixed with "/" in that example. So the
current parser won't handle that example currently. But this leaves the
possibility for expansion.

Sponsored-by: Joshua Antonishen on Patreon
2024-05-06 14:50:41 -04:00
Joey Hess
4b94fc371e
implement gitremote-helpers protocol parsing
Sponsored-by: Leon Schuermann on Patreon
2024-05-06 14:07:27 -04:00
Joey Hess
f17fa48b7c
ignore git-remote-annex 2024-05-06 13:13:39 -04:00
Joey Hess
306ea42447
improve git-remote-annex docs
renamed the git config to something shorter too
2024-05-06 13:06:22 -04:00
Joey Hess
a01d64a4ad
add git-remote-annex stub and build machinery
Renamed git-remote-annex.sh, keeping it around for now for reference.

Sponsored-by: Graham Spencer on Patreon
2024-05-06 13:05:58 -04:00
Joey Hess
0be9f7a2c6
add UUID to GITBUNDLE
The UUID is included in the GITMANIFEST in order to allow a single
key/value store to be used to store several special remotes, without any
namespacing. In that situation though, if the same ref is pushed to two
special remotes, it will result in git bundles with the same content.

Which is ok, until a re-push happens to one of the special remote.
At that point, the old git bundle will be deleted. That will prevent
fetching it from the other special remote, where the re-push has not
happened.

Adding the UUID avoids this problem.
2024-05-06 12:51:44 -04:00
Joey Hess
a8cef2bf85
added man page for git-remote-annex
And document remote.<name>.git-remote-annex-max-bundles which will
configure it.

datalad-annex uses a similar url format, but with some enhancements.
See https://github.com/datalad/datalad-next/blob/main/datalad_next/gitremotes/datalad_annex.py

I added the UUID to the URL, because it is needed in order to pick out which
manifest file to use. The design allows for a single key/value store to have
several special remotes all stored in it, and so the manifest includes
the UUID in its name.

While datalad-annex allows datalad-annex::<url>?, and allows referencing
peices of the url in the parameters, needing the UUID prevents
git-remote-annex from supporting that syntax. And anyway, it is a
complication and I want to keep things simple for now.

Sponsored-by: unqueued on Patreon
2024-05-06 12:48:04 -04:00
Joey Hess
90b389369f
fix name of gitremote-helpers
The git man page has that name.
2024-05-06 12:07:05 -04:00
Joey Hess
4007d7234b
update 2024-05-06 11:36:43 -04:00
Joey Hess
5f61667f27
note on cycles 2024-05-02 12:22:04 -04:00
Joey Hess
4c538b0bb9
question 2024-05-02 11:15:35 -04:00
Joey Hess
883328b615
Merge branch 'master' of ssh://git-annex.branchable.com 2024-05-02 11:11:19 -04:00
Joey Hess
008ffd5cb5
update with presigned url idea
Sponsored-by: Dartmouth College's OpenNeuro project
2024-05-02 11:10:23 -04:00
NewUser
54d3cc6ed6 2024-05-02 14:32:26 +00:00
NewUser
7e3b48a388 2024-05-02 14:31:22 +00:00
lell
13b21662c8 2024-05-02 09:06:21 +00:00
Yaroslav Halchenko
6674c3b055
A few more of typo fixes/skip as detected with bleeding edge codespell 2024-05-01 20:06:08 -04:00
Joey Hess
9dea552f9b
changelog for typo fixes
Since a few affected output messages.
2024-05-01 15:47:28 -04:00
Yaroslav Halchenko
9c2ab31549
Fix compatable typo (yet to add to codespell)
=== Do not change lines below ===
{
 "chain": [],
 "cmd": "git-sedi compatable compatible",
 "exit": 0,
 "extra_inputs": [],
 "inputs": [],
 "outputs": [],
 "pwd": "."
}
^^^ Do not change lines above ^^^
2024-05-01 15:46:25 -04:00
Yaroslav Halchenko
87e2ae2014
run codespell throughout fixing typos automagically
=== Do not change lines below ===
{
 "chain": [],
 "cmd": "codespell -w",
 "exit": 0,
 "extra_inputs": [],
 "inputs": [],
 "outputs": [],
 "pwd": "."
}
^^^ Do not change lines above ^^^
2024-05-01 15:46:21 -04:00
Yaroslav Halchenko
aa9f9333ea
one spotted visually typo 2024-05-01 15:46:18 -04:00
Yaroslav Halchenko
d20ecff73c
Fix one ambigous typo 2024-05-01 15:46:15 -04:00
Yaroslav Halchenko
d9d8598b0d
Adjust codespell config for new skips 2024-05-01 15:46:12 -04:00
Joey Hess
1cbf89f48f
Merge branch 'master' of ssh://git-annex.branchable.com 2024-05-01 15:27:48 -04:00
Joey Hess
cbaf2172ab
started on a design for P2P protocol over HTTP
Added to git-annex_proxies todo because this is something OpenNeuro
would need in order to use the git-annex proxy.

Sponsored-by: Dartmouth College's OpenNeuro project
2024-05-01 15:26:51 -04:00
yarikoptic
f70ae767dc question about assessing size of keys in tagged commits 2024-05-01 19:06:56 +00:00
Joey Hess
d28adebd6b
number list 2024-05-01 12:19:12 -04:00
Joey Hess
0d0c891ff9
add headers for tocs 2024-05-01 12:18:14 -04:00
Joey Hess
4cd2c980d2
toc 2024-05-01 12:14:59 -04:00
Joey Hess
901e02ccc3
design work on proxies for exporttree=yes
Sponsored-by: Dartmouth College's OpenNeuro project
2024-05-01 12:07:57 -04:00
Joey Hess
e7333aa505
fix link 2024-05-01 11:08:57 -04:00
Joey Hess
9cdbcedc37
additional design work on proxies
Sponsored-by: Dartmouth College's OpenNeuro project
2024-05-01 11:08:10 -04:00
Joey Hess
a612fe7299
add todo linking to two design docs and some related todos
Tagging with projects/openneuro as Christopher Markiewicz has oked
them funding at least the initial design work on this.
2024-05-01 11:04:20 -04:00
Joey Hess
5b36e6b4fb
comments 2024-04-30 16:08:46 -04:00
Joey Hess
fa0bcba86e
add news item for git-annex 10.20240430 2024-04-30 15:27:37 -04:00
Joey Hess
d6ad5b9b50
releasing package git-annex version 10.20240430 2024-04-30 15:27:31 -04:00
Joey Hess
d4ed1d9977
comment 2024-04-30 15:20:25 -04:00
Joey Hess
f3cca8a9f8
applied patch 2024-04-30 15:17:38 -04:00
Gergely Risko
cb541b9ecd
Change --copies' meta parameter to NUMBER 2024-04-30 15:16:22 -04:00
Joey Hess
1f37d0b00d
promote comment to todo 2024-04-30 15:13:59 -04:00
Joey Hess
da712198d8
close 2024-04-30 14:48:25 -04:00
Joey Hess
46aae325af
Merge branch 'master' of ssh://git-annex.branchable.com 2024-04-30 14:44:59 -04:00
Joey Hess
7a9633312e
got git clone from git-remote-annex prototype working
eg git clone annex://`pwd` when the MANIFEST file is in the pwd.

This is easy in the prototype, just use $GIT_DIR, but in git-annex, it
will need to automatically git-annex init, and set up the special
remote, in order to be able to download the manifest and bundle keys
from it.

Sponsored-by: k0ld on Patreon
2024-04-30 14:40:49 -04:00
Joey Hess
fc37243ffe
convert git-remote-annex to not include old pushed refs in new bundle
Rather than requiring the last listed bundle in the manifest include all
refs that are in the remote, build up refs from each bundle listed in
the manifest.

This fixes a bug where pushing first a new branch foo from one clone,
and then pushing a new branch bar from another clone, caused the second
push to lose branch foo. Now the second push will add a new bundle, but
the foo ref in the bundle from the first push will still be used.

Pushing a deletion of a ref now has to delete all bundles and push a new
bundle with only the remaining refs in it.

In a "list for-push", it now has to unbundle all bundles, in order for a
deletion repush to have available all objects. (And a non-deletion push
can also rely on refs/namespaces/mine/ being up-to-date.)

It would have been possible to fix the bug by only making it do that
unbundling in "list for-push", without changing what's stored in the
bundles. But I think I prefer to populate the bundles this way. For one
thing, deleting a pushed ref now really deletes all data relating to it,
rather than leaving it present in old bundles. For another, it's easier
to explain since there is no special case for the last bundle. And, it
will often result in smaller bundles.

Note that further efficiency gains are possible with respect to what
objects are included in an incremental bundle. Two XXX comments
document how to reduce excess objects. It didn't seem worth implementing
those optimisations in this proof of concept code.

Sponsored-by: Brock Spratlen on Patreon
2024-04-30 14:30:09 -04:00
rshalaev
77065b8569 Added a comment: How to find last available version of a file? 2024-04-29 14:07:40 +00:00
yarikoptic
3302390894 Added a comment 2024-04-29 13:13:48 +00:00
nobodyinperson
2fcfabe499 Added a comment: annex.maxextensionlength and annex.maxextensions 2024-04-27 19:16:29 +00:00