Fix doc path
[opentx.git] / tools / nightly22 / build-sdcard.sh.winbox
blobabc7eb51c6575bb3adc7dee602d81e0a77b4613b
1 #!/bin/bash
3 set -e
5 branch=2.2
6 workdir=/home/opentx/nightly22
7 output=/var/www/html/2.2/nightly
9 cd ${workdir}
11 # Copy git sdcard data
12 rm -Rf ${workdir}/sdcard
13 cp -r ${workdir}/code/radio/sdcard .
15 # Get images for Horus
16 mkdir -p ${workdir}/sdcard/horus/IMAGES
17 cp /home/opentx/horus-bitmaps/* ${workdir}/sdcard/horus/IMAGES/
19 # Request sound pack generation
20 wget -qO- http://winbox.open-tx.org/voice-builds/compile22.php?branch=${branch}
22 # Get sounds
23 cd sdcard
24 wget http://winbox.open-tx.org/voice-builds/english-irish-taranis.zip
25 wget http://winbox.open-tx.org/voice-builds/english-scottish-taranis.zip
26 wget http://winbox.open-tx.org/voice-builds/english-american-taranis.zip
27 wget http://winbox.open-tx.org/voice-builds/english-australian-taranis.zip
28 wget http://winbox.open-tx.org/voice-builds/french-taranis.zip
30 # Prepare the sdcard zip files for Horus
31 unzip english-irish-taranis.zip -d ${workdir}/sdcard/horus
32 mv ${workdir}/sdcard/horus/SOUNDS/en ${workdir}/sdcard/horus/SOUNDS/en-irish
33 unzip english-scottish-taranis.zip -d ${workdir}/sdcard/horus
34 mv ${workdir}/sdcard/horus/SOUNDS/en ${workdir}/sdcard/horus/SOUNDS/en-scottish
35 unzip english-australian-taranis.zip -d ${workdir}/sdcard/horus
36 mv ${workdir}/sdcard/horus/SOUNDS/en ${workdir}/sdcard/horus/SOUNDS/en-australian
37 unzip english-american-taranis -d ${workdir}/sdcard/horus
38 unzip french-taranis.zip -d ${workdir}/sdcard/horus
39 wget -O ${workdir}/sdcard/horus/SOUNDS/en/english.csv http://winbox.open-tx.org/voice-builds/english-american-taranis.csv
40 wget -O ${workdir}/sdcard/horus/SOUNDS/fr/french.csv http://winbox.open-tx.org/voice-builds/french-taranis.csv
42 # Duplicate for Taranis and create sdcards.zip
43 mkdir ${workdir}/sdcard/taranis/SOUNDS
44 cp -r ${workdir}/sdcard/horus/SOUNDS ${workdir}/sdcard/taranis/
45 rm -f ${workdir}/sdcard/*.zip
46 cd ${workdir}/sdcard/taranis && zip -r ${output}/sdcard/sdcard-taranis.zip *
47 cd ${workdir}/sdcard/horus && zip -r ${output}/sdcard/sdcard-horus.zip *
48 rm -Rf ${workdir}/sdcard