joeyh/git-annex — Issue #3: Special Remote Hook Fails On checkpresent
Author: lmbrt
Created: 2011-12-20 15:30:49+00:00
State: open

I'm trying to implement a custom hook that just compresses the files with xz and places them in a directory.

I've written a basic perl script and setup my config:
localdev-store-hook='perl ~/.bin/annexfile.pl ~/tmpstore/ store "$ANNEX_FILE" $ANNEX_KEY $ANNEX_HASH_1 $ANNEX_HASH_2'
localdev-retrieve-hook='perl ~/.bin/annexfile.pl ~/tmpstore/ retrieve "$ANNEX_FILE" $ANNEX_KEY $ANNEX_HASH_1 $ANNEX_HASH_2'
localdev-remove-hook='perl ~/.bin/annexfile.pl ~/tmpstore/ remove "$ANNEX_FILE" $ANNEX_KEY $ANNEX_HASH_1 $ANNEX_HASH_2'
localdev-checkpresent-hook='perl ~/.bin/annexfile.pl ~/tmpstore/ checkpresent "" $ANNEX_KEY $ANNEX_HASH_1 $ANNEX_HASH_2'

I managed to initremote without issue, but when I try and add a copy a file, I get this error:
git-annex: Remote/Hook.hs:(70,17)-(71,70): Irrefutable pattern failed for pattern [hash_1, hash_2, _rest]

I've tried several versions and all have the same result...

Thoughts?