File: orig-tar.sh

package info (click to toggle)
libjtype-java 0.1.3-4
  • links: PTS, VCS
  • area: main
  • in suites: buster, stretch
  • size: 380 kB
  • ctags: 829
  • sloc: java: 4,599; xml: 210; sh: 13; makefile: 5
file content (20 lines) | stat: -rwxr-xr-x 453 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
#!/bin/sh -e

# called by uscan with '--upstream-version' <version> <file>
SOURCE=$(dpkg-parsechangelog | sed -ne 's,Source: \(.*\),\1,p')
TAR=../${SOURCE}_$2.orig.tar.xz
DIR=$SOURCE-$2
TAG=$2
SVN=http://jtype.googlecode.com/svn/tags/

svn export $SVN/$TAG $DIR
XZ_OPT=--best tar -c -J -f $TAR $DIR
rm -rf $3 $DIR

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