Fix filter_commit in common_translation_update.sh

This fixes a problem with propose_translation_update.sh on
oslo.concurrency:

+ git reset -q oslo.concurrency/locale/en_GB/LC_MESSAGES/oslo.concurrency-log-error.po
fatal: ambiguous argument
'oslo.concurrency/locale/en_GB/LC_MESSAGES/oslo.concurrency-log-error.po': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'

Add the "--" to separate paths to handle deleted files as well.

Change-Id: Ifbce50bd851ea0028ebbb948e5173bda5777fc43
This commit is contained in:
Andreas Jaeger 2015-06-16 20:08:43 +02:00
parent f88572c250
commit a0e27a5933

View File

@ -338,7 +338,7 @@ function filter_commits {
# their own.
if [ $PO_CHANGE -eq 0 ] ; then
for f in $(git diff --cached --name-only) ; do
git reset -q "$f"
git reset -q -- "$f"
git checkout -- "$f"
done
fi