From 7677a5fb6485dbe823dcc111344d75303d2ac5c7 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Thu, 6 Sep 2012 00:50:45 -0400 Subject: [PATCH] cp-po: Fix delete mode --- cp-po | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/cp-po b/cp-po index 499bc4c..25627ae 100755 --- a/cp-po +++ b/cp-po @@ -144,12 +144,13 @@ if $delete && [ -n "$qualfile" ]; then for lang in $destlang; do if ! grep -q -F "$destcat/$lang" "$qualfile"; then if $run && $update_target_tree; then - rm $targetdir/po/$lang.po if $git_mode; then - git rm -q $targetdir/po/$lang.po + (cd $targetdir && git rm -q --ignore-unmatch $lang.po) + else + rm -f $targetdir/$lang.po fi else - echo "should DELETE unqualified: $targetdir/po/$lang.po" 1>&2 + echo "should DELETE unqualified: $targetdir/$lang.po" 1>&2 fi fi done -- 2.39.5