This commit is contained in:
Joey Hess 2019-04-09 15:50:52 -04:00
parent 7bf18f23e5
commit 5a570da1ab
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38

View file

@ -193,12 +193,23 @@ The situations to keep in mind are these:
and before it's downloaded, so the wrong version gets downloaded. and before it's downloaded, so the wrong version gets downloaded.
Need to detect this and fail the import. Need to detect this and fail the import.
The api design has some requirements that, if followed, makes those The API design has some requirements that, if followed, makes those
situations be handled well. situations be handled well. The directory special remote is thus
able to avoid these situations as well as git does, and the S3 special
remote with versioning is able to recover data after those situations.
## api design But.. Other types of remotes are limited by remote APIs that don't
let this be dealt with. If the limitation is explained to the user,
and they understand how to avoid these situations, importing from
such remotes could still be supported. Eg, if a user understands
that modifications they make to files using their phone may get overwritten
while git-annex is exporting to it, and so avoids using their phone during
that process (or chooses to only ever modify certian files on their phone),
then git-annex can safely support importing from their phone.
This is an extension to the ExportActions api. ## API design
This is an extension to the ExportActions API.
listContents :: Annex (ContentHistory [(ExportLocation, ContentIdentifier)]) listContents :: Annex (ContentHistory [(ExportLocation, ContentIdentifier)])