chiark
/
gitweb
/
~cjwatson
/
bin.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
1ddf5a9
)
handle non-existent targets
author
Colin Watson
<cjwatson@chiark.greenend.org.uk>
Tue, 3 Apr 2007 16:27:14 +0000
(16:27 +0000)
committer
Colin Watson
<cjwatson@chiark.greenend.org.uk>
Tue, 3 Apr 2007 16:27:14 +0000
(16:27 +0000)
rosetta-merge
patch
|
blob
|
history
diff --git
a/rosetta-merge
b/rosetta-merge
index 58bb1fab38fe2d90b810d0fafb148e12904ed563..2e8c1dab1e8f1ec88bb7c6e5b9de0fb60fb982d9 100755
(executable)
--- a/
rosetta-merge
+++ b/
rosetta-merge
@@
-16,4
+16,14
@@
case $2 in
esac
[ -e $1/$ROSETTA_LANG.po ] || exit
esac
[ -e $1/$ROSETTA_LANG.po ] || exit
-msgmerge -q -N <(msgconv -t UTF-8 $1/$ROSETTA_LANG.po | msgattrib --no-obsolete -) *.pot | msgattrib --no-obsolete $MSGATTRIB_OPTS - | msgmerge -q -N - <(msgconv -t UTF-8 $2.po | msgattrib --no-obsolete -) | msgattrib --no-obsolete - | if $APPLY; then sponge $2.po; else diff -u --label $2.po <(msgconv -t UTF-8 $2.po) -; fi
+msgmerge -q -N <(msgconv -t UTF-8 $1/$ROSETTA_LANG.po | msgattrib --no-obsolete -) *.pot | msgattrib --no-obsolete $MSGATTRIB_OPTS - | \
+ if [ -e $2.po ]; then
+ msgmerge -q -N - <(msgconv -t UTF-8 $2.po | msgattrib --no-obsolete -) | msgattrib --no-obsolete -
+ else
+ cat
+ fi | \
+ if $APPLY; then
+ sponge $2.po
+ else
+ diff -u --label $2.po <(msgconv -t UTF-8 $2.po) -
+ fi