File: orig-tar.sh

package info (click to toggle)
netbeans-cvsclient 6.5-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 2,360 kB
  • sloc: java: 20,291; xml: 244; sh: 18; makefile: 10
file content (23 lines) | stat: -rwxr-xr-x 500 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
#!/bin/sh -e

VERSION=$2
TAR=../netbeans-cvsclient_$VERSION.orig.tar.gz
DIR=netbeans-cvsclient-$VERSION
TAG=$(echo release${VERSION}_base | sed -e's/\.//')

hg clone http://hg.netbeans.org/main/file/$TAG/lib.cvsclient $DIR.tmp
cd $DIR.tmp
hg update $TAG
cd ..
mkdir $DIR
mv $DIR.tmp/lib.cvsclient/* $DIR
rm -r $DIR.tmp
tar -c -z -f $TAR $DIR
rm -rf $DIR ../$TAG

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