blob: b5934d4398930ea36e46584c89b9346a2dc2fc50 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
#!/bin/sh
usage() {
echo 1>&2 << EOF
cws-extract [-s] cws_name
Create a patch from an up-stream CWS suitable for ooo-build.
-s Don't ignore changes in whitespace.
EOF
exit 1;
}
echo "Warning! This is the SVN version of cws-extract, use
cws-extract-cvs for the older OOo CWSes."
CWS=""
DIFFPARAMS="-ubwp"
while [ -n "$1" ] ; do
case "$1" in
-s) DIFFPARAMS="-up"
;;
*) CWS="$1"
;;
esac
shift
done
[ -n "$CWS" ] || usage
# log of the branch only
MERGE_BASE=`svn log --stop-on-copy "svn+ssh://svn@svn.services.openoffice.org/ooo/cws/$CWS" | \
grep 'CWS-TOOLING: \(rebase\|create\) CWS' | head -n 1 | \
sed 's/^.*trunk@\([0-9]\+\).*$/\1/'`
if [ -n "$MERGE_BASE" ] ; then
svn diff -x "$DIFFPARAMS" "svn+ssh://svn@svn.services.openoffice.org/ooo/trunk@$MERGE_BASE" "svn+ssh://svn@svn.services.openoffice.org/ooo/cws/$CWS" > "cws-$CWS.diff"
fi
|