]> TLD Linux GIT Repositories - packages/php.git/blobdiff - php-branch.sh
- PHP_5_4 branch from PLD
[packages/php.git] / php-branch.sh
diff --git a/php-branch.sh b/php-branch.sh
new file mode 100644 (file)
index 0000000..d9f5fbd
--- /dev/null
@@ -0,0 +1,25 @@
+#!/bin/sh
+set -e
+svn=http://svn.php.net/repository/php/php-src
+tag=php_5_3_2
+branch=PHP_5_3
+out=php-branch.diff
+
+d=$-
+filter() {
+       set -$d
+       # remove revno's for smaller diffs
+       sed -e 's,^\([-+]\{3\} .*\)\t(revision [0-9]\+)$,\1,'
+}
+
+old=$svn/tags/$tag
+new=$svn/branches/$branch
+echo >&2 "Running diff: $old -> $new"
+LC_ALL=C svn diff --old=$old --new=$new | filter > $out.tmp
+
+if cmp -s $out{,.tmp}; then
+       echo >&2 "No new diffs..."
+       rm -f $out.tmp
+       exit 0
+fi
+mv -f $out{.tmp,}