upload-package.sh

Cesar Martinez Izquierdo, 12/10/2015 02:20 PM

Download (1023 Bytes)

 
1
#!/bin/sh
2

    
3

    
4
usage () {
5
    echo "Usage: upload-package.sh gvsig-version"
6
    echo "  It must be run from the base of the osgeo package."
7
    echo "  Example:"
8
    echo "    $ cd gvsig-osgeo-package"
9
    echo '    $ ../upload-package.sh "2.2.0_2"'
10
}
11

    
12
if [ $# -ne 1 ]; then
13
    echo "Version parameter is missing"
14
    usage
15
    return 1 ;
16
fi
17

    
18
if [ -d "apps/gvsig" ] && [ -d "etc" ] ; then
19
    tar -cvjf ../gvsig-"$1".tar.bz2 *
20
    scp ../gvsig-"$1".tar.bz2 cmartinez@upload.osgeo.org:/osgeo/download/osgeo4w/x86/release/gvsig
21
    # regenerate package index
22
    echo "Launch http://upload.osgeo.org/cgi-bin/osgeo4w-regen.sh to regenerate the package index"
23
    #curl http://upload.osgeo.org/cgi-bin/osgeo4w-regen.sh
24

    
25
    # promote test setup to live
26
    echo "Launch http://upload.osgeo.org/cgi-bin/osgeo4w-promote.sh to promote test setup to live"
27
    #curl http://upload.osgeo.org/cgi-bin/osgeo4w-promote.sh
28
else
29
    echo "Current working directory does not appear to be an osgeo gvsig package"
30
    usage
31
    return 1 ;
32
fi
33