Fix metadata hook behavior when multiple files are added at once. Thanks, Klaus Ethgen.

This commit is contained in:
Joey Hess 2016-03-02 12:25:41 -04:00
parent 12f7c0724f
commit baa9954e06
Failed to extract signature
2 changed files with 4 additions and 2 deletions

2
debian/changelog vendored
View file

@ -4,6 +4,8 @@ git-annex (6.20160230) UNRELEASED; urgency=medium
* Fix data loss that can occur when annex.pidlock is set in a repository.
* Fix bug preventing moving files to/from a repository with annex.pidlock set.
* Fix shared lock file FD leak.
* Fix metadata hook behavior when multiple files are added at once.
Thanks, Klaus Ethgen.
-- Joey Hess <id@joeyh.name> Mon, 29 Feb 2016 13:00:30 -0400

View file

@ -1,4 +1,4 @@
#! /bin/sh
#!/bin/sh
#
# Copyright (C) 2014 Joey Hess <id@joeyh.name>
# Copyright (C) 2016 Klaus Ethgen <Klaus@Ethgen.ch>
@ -112,7 +112,7 @@ if [ -n "$*" ]; then
process "$f"
done
else
for f in "$(git diff-index --name-only --cached $against)"; do
git diff-index --name-only --cached $against | while read f; do
process "$f"
done
fi