Revision 101
org.gvsig.educa.thematicmap.app/trunk/org.gvsig.educa.thematicmap.app/testing/prepare-to-upload.sh | ||
---|---|---|
1 |
#!/bin/bash |
|
2 |
|
|
3 |
############################################## |
|
4 |
# Script to generate the contents to upload |
|
5 |
# to gvSIG for add-on functionally test |
|
6 |
############################################# |
|
7 |
|
|
8 |
SCRIPT_PATH=`readlink -f $0` |
|
9 |
SRC_DIR=`dirname "$SCRIPT_PATH"` |
|
10 |
TARGET_DIR="$SRC_DIR/target" |
|
11 |
if [ -e "$TARGET_DIR" ] ; then |
|
12 |
echo "Cleaning work folder..." |
|
13 |
rm -r $TARGET_DIR |
|
14 |
fi |
|
15 |
|
|
16 |
echo "Creating work folder ($TARGET_DIR)..." |
|
17 |
mkdir "$TARGET_DIR" |
|
18 |
echo "Copying source files..." |
|
19 |
cp "$SRC_DIR/org.gvsig.educa.thematicmap.mm" $TARGET_DIR |
|
20 |
tar c --exclude-vcs geodata | tar x -C $TARGET_DIR |
|
21 |
tar c --exclude-vcs resources | tar x -C $TARGET_DIR |
|
22 |
cd $TARGET_DIR |
|
23 |
echo "Ziping geodata..." |
|
24 |
zip -r org.gvsig.educa.thematicmap-data.zip geodata |
|
25 |
rm -r "$TARGET_DIR/geodata" |
|
26 |
echo "Ziping resource..." |
|
27 |
zip -r org.gvsig.educa.thematicmap-resources.zip resources |
|
28 |
rm -r "$TARGET_DIR/resources" |
|
29 |
echo "Done!" |
|
30 |
echo "Folder $TARGET_DIR contains the files to upload for testing." |
|
31 |
echo "" |
|
0 | 32 |
Also available in: Unified diff