]> git.pld-linux.org Git - packages/ctags.git/blame - branch.sh
fix build with modern gcc/glibc
[packages/ctags.git] / branch.sh
CommitLineData
26a0fca0
ER
1#!/bin/sh
2set -e
b95a0071 3package=ctags
26a0fca0
ER
4svn=svn://svn.code.sf.net/p/ctags/code
5tag=ctags-5.8
6out=branch.diff
7
8d=$-
9filter() {
10 set -$d
11 # Excluding files which change version or were not in dist tarball
12 filterdiff \
13 -x 'NEWS' \
14 -x 'maintainer.mak' \
15 -x 'Test/*' \
16 -x 'website/*' \
17 | \
18 # remove revno's for smaller diffs
19 sed -e 's,^\([-+]\{3\} .*\)\t(revision [0-9]\+)$,\1,'
20}
21
22old=$svn/tags/$tag
23new=$svn/trunk
24echo >&2 "Running diff: $old -> $new"
25LC_ALL=C svn diff --old=$old --new=$new > $out.tmp
26revno=$(sed -ne 's,^[-+]\{3\} .*\t(revision \([0-9]\+\))$,\1,p' $out.tmp | sort -urn | head -n1)
27echo >&2 "Revision $revno"
28[ "$revno" -gt 0 ] || exit 1
29
30sed -i -e "1i# Revision $revno" $out.tmp
31filter < $out.tmp > $out.tmp2 && mv -f $out.{tmp2,tmp}
32
b95a0071 33if cmp -s $out{,.tmp}; then
26a0fca0 34 echo >&2 "No new diffs..."
b95a0071 35 rm -f $out.tmp
26a0fca0
ER
36 exit 0
37fi
b95a0071
ER
38mv -f $out{.tmp,}
39
40../md5 $package.spec
41../dropin $out
This page took 0.15921 seconds and 4 git commands to generate.