File: orig-tar.sh

package info (click to toggle)
libitext-java 2.1.7-11
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 9,624 kB
  • ctags: 15,568
  • sloc: java: 94,208; xml: 1,049; sh: 15; makefile: 8
file content (24 lines) | stat: -rwxr-xr-x 678 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh

set -e

VERSION=$(dpkg-parsechangelog | sed -ne 's,^Version: \(.*\)-.*,\1,p')
SOURCE=$(dpkg-parsechangelog | sed -ne 's,Source: \(.*\),\1,p')

SVNROOT=http://svn.code.sf.net/p/itext/code/tags/iText_$(echo $VERSION | sed -e s/\\./_/g)/src

echo $SVNROOT

DIR=$SOURCE
TAR=../${SOURCE}_${VERSION}.orig.tar.gz

svn export $SVNROOT $DIR
find $DIR -name \*.java -o -name \*.ps -o -name \*.txt -o -name \*.gif -o -name \*.png -o -name \*.afm -o -name \*.html -o -name \*.xml -o -name \.ant*.properties | xargs tar -zcf $TAR
rm -rf $DIR

# move to directory 'tarballs'
if [ -r .svn/deb-layout ]; then
  . .svn/deb-layout
  mv $TAR $origDir
  echo "moved $TAR to $origDir"
fi