2 # --- T2-COPYRIGHT-NOTE-BEGIN ---
3 # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
5 # T2 SDE: package/.../clip/getpatch.sh
6 # Copyright (C) 2004 - 2006 The T2 SDE Project
8 # More information can be found in the files COPYING and README.
10 # This program is free software; you can redistribute it and/or modify
11 # it under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; version 2 of the License. A copy of the
13 # GNU General Public License can be found in the file COPYING.
14 # --- T2-COPYRIGHT-NOTE-END ---
16 tempfile
=clip-patch.
tar.gz.$$
17 #location=ftp://ftp.linux.ru.net/mirrors/clip
18 location
=ftp://www.cis.by
/pub
/clip
/pub
/clip
19 #location=ftp://ftp.itk.ru/pub/clip
21 echo "get: $location/patch.tgz"
22 if [ -f patch.tgz
]; then
23 mv patch.tgz
$tempfile
25 # wget $location/patch.tgz -O $tempfile
26 curl
$location/patch.tgz
-o $tempfile
33 release
=$
( tar zOxf
$tempfile .
/clip-prg
/clip
/release_version
2> /dev
/null
)
34 [ -z "$release" ] && release
=$
( grep -e '^\[V\]' clip.desc | cut
-d' ' -f2- | cut
-d'-' -f1)
35 seqno
=$
( tar zOxf
$tempfile .
/clip-prg
/clip
/seq_no.txt
2> /dev
/null
)
37 echo "$release-$seqno"
39 if [ -n "$release" -a -n "$seqno" ]; then
40 archdir
=..
/..
/..
/download
/mirror
/c
/
41 filename
=clip-patch-
$release-$seqno.tbz2
43 if [ -f $archdir/$filename ]; then
44 echo "INFO: $filename already grabbed"
46 zcat .
/$tempfile |
bzip2 - > $archdir/$filename
47 echo "INFO: $filename catched!"
50 ( cd ..
/..
/..
; sh misc
/archive
/Update.sh clip
$release-$seqno )
52 echo "ERROR: take a look into ./$tempfile"