]> git.pld-linux.org Git - packages/lighttpd.git/blame - branch.sh
up to 1.4.38
[packages/lighttpd.git] / branch.sh
CommitLineData
68f8f1d1 1#!/bin/sh
51e3e0fc
ER
2set -e
3svn=svn://svn.lighttpd.net/lighttpd
c2f7af02
ER
4package=lighttpd
5tag=lighttpd-1.4.36
6branch=lighttpd-1.4.x
7out=lighttpd-branch.diff
8
9# old version of this code used to create tarball.
10# leave it around
11if [ "$1" = "tarball" ]; then
12 v=1.5
13 svn co $svn/trunk $package-$v
14 r=$(svnversion $package-$v)
15 t=$package-r$r.tar.bz2
16 tar -cjf $t --exclude-vcs $package-$v
17 ../dropin $t &
18 exit 0
19fi
20
21d=$-
22filter() {
23 set -$d
fc34d589
ER
24 # Excluding files which change version or were not in dist tarball
25 filterdiff \
26 -x 'CMakeLists.txt' \
27 -x 'configure.ac' \
28 -x 'SConstruct' \
29 | \
c2f7af02
ER
30 # remove revno's for smaller diffs
31 sed -e 's,^\([-+]\{3\} .*\)\t(revision [0-9]\+)$,\1,'
32}
33
34old=$svn/tags/$tag
35new=$svn/branches/$branch
36echo >&2 "Running diff: $old -> $new"
37LC_ALL=C svn diff --old=$old --new=$new > $out.tmp
38revno=$(sed -ne 's,^[-+]\{3\} .*\t(revision \([0-9]\+\))$,\1,p' $out.tmp | sort -urn | head -n1)
39echo >&2 "Revision $revno"
40[ "$revno" -gt 0 ] || exit 1
41
42sed -i -e "1i# Revision $revno" $out.tmp
43filter < $out.tmp > $out.tmp2 && mv -f $out.{tmp2,tmp}
44
45if cmp -s $out{,.tmp}; then
46 echo >&2 "No new diffs..."
47 rm -f $out.tmp
48 exit 0
49fi
50mv -f $out{.tmp,}
4292d306 51
d0faf49f
ER
52../md5 $package.spec
53../dropin $out
This page took 0.121653 seconds and 4 git commands to generate.