Annotation of /trunk/xf86-video-nouveau/make-git-snapshot.sh
Parent Directory | Revision Log
Revision 2724 -
(hide annotations)
(download)
(as text)
Mon Nov 23 13:45:00 2015 UTC (8 years, 11 months ago) by niro
File MIME type: application/x-sh
File size: 747 byte(s)
Mon Nov 23 13:45:00 2015 UTC (8 years, 11 months ago) by niro
File MIME type: application/x-sh
File size: 747 byte(s)
-fixed pver
1 | niro | 1334 | #!/bin/sh |
2 | |||
3 | # Usage: ./make-git-snapshot.sh [COMMIT] | ||
4 | # | ||
5 | # to make a snapshot of the given tag/branch. Defaults to HEAD. | ||
6 | |||
7 | MODULE=xf86-video-nouveau | ||
8 | niro | 2724 | DIRNAME=${MODULE}-1.0.11_$( date +%Y%m%d ) |
9 | niro | 1334 | DESTINATION="root@cvs.magellan-linux.de:/var/www/htdocs/magellan/magellan-dev/sources/${MODULE}/" |
10 | |||
11 | echo DIRNAME ${DIRNAME} | ||
12 | echo HEAD ${1:-HEAD} | ||
13 | |||
14 | rm -rf ${DIRNAME} | ||
15 | |||
16 | git clone git://anongit.freedesktop.org/git/nouveau/${MODULE} ${DIRNAME} | ||
17 | |||
18 | GIT_DIR=${DIRNAME}/.git git archive --format=tar --prefix=${DIRNAME}/ ${1:-HEAD} \ | ||
19 | | bzip2 > ${DIRNAME}.tar.bz2 | ||
20 | |||
21 | echo "Uploading latest tarball for ${DIRNAME}" | ||
22 | scp ${DIRNAME}.tar.bz2 ${DESTINATION} | ||
23 | |||
24 | if [[ -d ${DIRNAME} ]] | ||
25 | then | ||
26 | rm -rf ${DIRNAME} | ||
27 | fi | ||
28 | if [[ -f ${DIRNAME}.tar.bz2 ]] | ||
29 | then | ||
30 | rm ${DIRNAME}.tar.bz2 | ||
31 | fi | ||
32 | |||
33 | exit 0 |