wok-6.x rev 13286
get-wfica: allow downloadId arg
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Aug 25 11:17:45 2012 +0200 (2012-08-25) |
parents | e84d6bf204b2 |
children | 3fd2f1836a8c |
files | get-wfica/stuff/get-wfica syslinux/receipt |
line diff
1.1 --- a/get-wfica/stuff/get-wfica Fri Aug 24 22:35:04 2012 +0200 1.2 +++ b/get-wfica/stuff/get-wfica Sat Aug 25 11:17:45 2012 +0200 1.3 @@ -2,7 +2,8 @@ 1.4 1.5 PACKAGE="wfica" 1.6 WEB_SITE="http://www.citrix.com" 1.7 -PROD="downloadId=2323812&productId=1689163&ntref=downloadreceiver" 1.8 +PROD="productId=1689163&ntref=downloadreceiver&downloadId=" 1.9 +DLID="2323812" 1.10 INSTALL_USB=yes 1.11 1.12 ROOT="$1" 1.13 @@ -24,10 +25,23 @@ 1.14 CUR_DIR=$(pwd) 1.15 mkdir -p $TMP_DIR && cd $TMP_DIR 1.16 1.17 -URL="$WEB_SITE$(wget -O - "$WEB_SITE/English/ss/downloads/details.asp?$PROD" | \ 1.18 - sed "/Download/h;/\.deb/!d;g;s/.*([\"']\([^\"']*\).*/\1/;q")" 1.19 -USB_URL="$WEB_SITE$(wget -O - "$WEB_SITE/English/ss/downloads/details.asp?$PROD" | \ 1.20 - sed "1,/\.deb/d;/Download/h;/\.deb/!d;g;s/.*([\"']\([^\"']*\).*/\1/;q")" 1.21 +for i in $@ $DLID; do 1.22 + [ -z "$(echo $i | sed 's/[0-9]//g')" ] && break 1.23 +done 1.24 +url="$WEB_SITE/English/ss/downloads/details.asp?$PROD$i" 1.25 +filter="/Download/h;/\.deb/!d;g;s/.*([\"']\([^\"']*\).*/\1/;q" 1.26 +URL="$(wget -O - "$url" | sed "$filter")" 1.27 +if [ -n "$URL" ]; then 1.28 + URL="$WEB_SITE$URL" 1.29 + USB_URL="$WEB_SITE$(wget -O - "$url" | sed "1,/\.deb/d;$filter")" 1.30 +else 1.31 + cat 2>&1 <<EOT 1.32 +DownloadId $i not found on $WEB_SITE. 1.33 +Try again with the correct downloadId : 1.34 +# $0 <downloadId> 1.35 +EOT 1.36 + exit 1 1.37 +fi 1.38 1.39 wget -O $PACKAGE.deb "$URL" 1.40 mkdir $PACKAGE
2.1 --- a/syslinux/receipt Fri Aug 24 22:35:04 2012 +0200 2.2 +++ b/syslinux/receipt Sat Aug 25 11:17:45 2012 +0200 2.3 @@ -56,7 +56,7 @@ 2.4 break 2.5 done 2.6 done <<EOT 2.7 -cr hr,croat hr_HR Hvratski 2.8 +br br-abnt2 pt_PT@euro Brazil 2.9 cz cz-lat2 cs_CZ Cesky 2.10 dk dk-latin1 da_DK Dansk 2.11 de de-latin1 de_DE@euro Deutsch 2.12 @@ -74,18 +74,18 @@ 2.13 be be-latin1 fr_FR@euro Francais Belgique 2.14 ca cf fr_FR Francais Canada 2.15 fr_CH\ frCH fr_CH-latin1 fr_FR Francais Suisse 2.16 -fi fi-latin1 fi_FI@euro Suomi 2.17 +cr hr,croat hr_HR Hvratski 2.18 is is-latin1 is_IS Islenska 2.19 it it it_IT@euro Italiano 2.20 -no no-latin1 nn_NO Norske 2.21 jp jp106 ja_JP Japanese 2.22 hu hu hu_HU Magyar 2.23 +no no-latin1 nn_NO Norske 2.24 po pl2 pl_PL Polski 2.25 -br br-abnt2 pt_PT@euro Brazil 2.26 pt pt-latin1 pt_PT@euro Portugues 2.27 ru ru ru_UA Russian 2.28 +sl slovene sl_SI Slovenski 2.29 +fi fi-latin1 fi_FI@euro Suomi 2.30 se se-lat6 sv_SE Svenskt 2.31 -sl slovene sl_SI Slovenski 2.32 tr trq tr_TR Turk 2.33 tr2 tr_q-latin5 tr_TR Turk latin5 2.34 EOT