intercept file access to git-annex repos

2012-04-16 Thread Thomas Koch
Hi,

still about photos and git-annex: When my wife edits photos prior to uploading 
them, it would be fine if she wouldn't need to know about git-annex. Hacking 
git-annex support in every photo application is no option.

But is there any linux kernel or LD_PRELOAD magic that could intercept access 
to a git-annex repo and make it look normal? (I just realize that we already 
talked about a fuse filesystem for git-annex.)

The interceptor should show the real files instead of symlinks and should do an 
edit-add roundtrip for any write access.

Regards,

Thomas Koch, http://www.koch.ro
___
vcs-home mailing list
vcs-home@lists.madduck.net
http://lists.madduck.net/listinfo/vcs-home


Re: more git-annex plumbing

2012-04-16 Thread Klaus Ethgen
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

Hello,

Am Mo den 16. Apr 2012 um 10:59 schrieb Thomas Koch:
 I have a few things that I'd like to do with git-annex but that are hard 
 because git-annex does not expose internal plumbing commands. I intend to 
 start a list of such commands here with possible use cases:
 
 - calculate checksum of a file
 - doesAnnexHasChecksum?
 - doesAnnexHasFile?
 
   Useful to deduplicate files from many old CD backups
 
 - checksum to path
 - move file into annex

Especially the second last I was searching for many times. I did this
with some pipe doing readlink and grep.

Regards
   Klaus
- -- 
Klaus Ethgen  http://www.ethgen.ch/
pub  4096R/4E20AF1C 2011-05-16   Klaus Ethgen kl...@ethgen.de
Fingerprint: 85D4 CA42 952C 949B 1753  62B3 79D0 B06F 4E20 AF1C
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)

iQGcBAEBCgAGBQJPjEZsAAoJEKZ8CrGAGfasz5UMAKobMuG8eVaqOdA/TDjsUg5E
pTDnAcv91dgUDjLn/lPl6Si2uDpDqhyBX56qHShRaeQ5z17Wps1t6ij5srs2c1BY
mX0kvKbrQyPB4czOrCX9fISjTivjCoxbBbgMe9IdH0Nbz4Ul9vB60IuhUnZ47Dlc
83X4sc+s9ODoPvCEMI+OKT6rr/ImRgeE9a/pglUasjNCukipolcB7V3RIaitnC3q
xS4Cz62/oWoy4cIKbpSvNtiP6bRaZP6WtVxJxr526L+/WEuzXjbb8nSWnk4j81R/
A7PGANXZryrUkVbj3zCsZO37evfMtFQpf/FT8I1rkvpOpFzHqW+IFOt8QOUtcW9/
CWykqsO92Z8Q1YWtTbv7oRC59kAKhpMjz3SbDmI5GZyRAEHW14f99FRDQsLg5WkN
oFsCmJbGkRXB0zTM1vuPGsooYzIHW1NUppijm233aAzlLMR17lHKhp9jzqgTdhbI
6hxvcWVjpBZwA/0X3ZYhy8TGvWNfwYu2NfZS+vBlSg==
=2Yca
-END PGP SIGNATURE-
___
vcs-home mailing list
vcs-home@lists.madduck.net
http://lists.madduck.net/listinfo/vcs-home


Re: intercept file access to git-annex repos

2012-04-16 Thread Joey Hess
Thomas Koch wrote:
 Hi,
 
 still about photos and git-annex: When my wife edits photos prior to 
 uploading 
 them, it would be fine if she wouldn't need to know about git-annex. Hacking 
 git-annex support in every photo application is no option.
 
 But is there any linux kernel or LD_PRELOAD magic that could intercept access 
 to a git-annex repo and make it look normal? (I just realize that we 
 already 
 talked about a fuse filesystem for git-annex.)

http://git-annex.branchable.com/todo/automatic_bookkeeping_watch_command/

I have a proof of concept branch using inotify, however, to make it
truely end user friendly with syncing is going to be a lot more work. I
have been thinking about doing a Kickstarter to pay for 3 months of my
time to seriously tackle this.

-- 
see shy jo


signature.asc
Description: Digital signature
___
vcs-home mailing list
vcs-home@lists.madduck.net
http://lists.madduck.net/listinfo/vcs-home

Re: more git-annex plumbing

2012-04-16 Thread Joey Hess
Thomas Koch wrote:
 Hi,
 
 I have a few things that I'd like to do with git-annex but that are hard 
 because git-annex does not expose internal plumbing commands. I intend to 
 start a list of such commands here with possible use cases:
 
 - calculate checksum of a file
 - doesAnnexHasChecksum?
 - doesAnnexHasFile?

   Useful to deduplicate files from many old CD backups

git annex find --format can be used to get at this to some extent.
But I'd instead suggest to just add the files, let git-annex deduplicate
the data, which it does automatically, and if desired dedup the
filenames afterwards.

 - checksum to path
 - move file into annex
 
   You already have an annexed file somewhere on the disk and just want to 
 move 
 it in the local annex without copying it

Sounds like the reinject command, I think?

 - find duplicates
 
   It might happen that a file is put into an annex in multiple places. One 
 could try to find duplicate symlinks, but that's inefficient. As I 
 understand, 
 the git-annex data should allow a quick lookup of all symlinks pointing to a 
 particular checkum.

http://git-annex.branchable.com/tips/finding_duplicate_files/

-- 
see shy jo


signature.asc
Description: Digital signature
___
vcs-home mailing list
vcs-home@lists.madduck.net
http://lists.madduck.net/listinfo/vcs-home