Magellan Linux

Annotation of /trunk/eglibc/make-svn-snapshot.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2505 - (hide annotations) (download) (as text)
Thu Apr 3 22:34:09 2014 UTC (10 years, 1 month ago) by niro
File MIME type: application/x-sh
File size: 1004 byte(s)
-snapshot script for eglibc
1 niro 2505 #!/bin/bash
2    
3     export LC_ALL=C
4    
5     branch="$1"
6     if [[ -z ${branch} ]]
7     then
8     echo "please tell me a branch!"
9     echo "e.g. $0 eglibc-2_12"
10     exit 1
11     fi
12    
13     temp=$(mktemp -d)
14     svn_base_uri="http://www.eglibc.org/svn/branches/${branch}"
15     svn_module="eglibc"
16     tarball_prefix="${svn_module}"
17     destination="root@cvs.magellan-linux.de:/var/www/htdocs/magellan/magellan-dev/sources/${svn_module}/"
18    
19     echo -n "building latest tarball for ${tarball_prefix}... "
20     cd ${temp}
21     svn checkout ${svn_base_uri} ${svn_module}
22     branchver="${branch/eglibc-/}"
23     branchver="${branchver//_/.}.0"
24     latest_version="${branchver}_$(date +%Y%m%d)"
25     mv ${temp}/${svn_module} ${tarball_prefix}-${latest_version}
26     find ./${tarball_prefix}-${latest_version} -name .svn | xargs rm -r
27     find ./${tarball_prefix}-${latest_version} -name .svnignore | xargs rm
28     tar cvjf ${tarball_prefix}-${latest_version}.tar.bz2 ./${tarball_prefix}-${latest_version}
29     scp ${tarball_prefix}-${latest_version}.tar.bz2 ${destination}
30    
31     if [[ -d ${temp} ]]
32     then
33     rm -rf ${temp}
34     fi
35    
36     exit 0