We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f6bbbc1 commit 9b40508Copy full SHA for 9b40508
mediawiki/scripts/install_extensions.sh
@@ -19,9 +19,17 @@ declare -a extension_names=( \
19
)
20
21
function fetch_extension_url() {
22
- curl -s "https://www.mediawiki.org/wiki/Special:ExtensionDistributor?extdistname=$1&extdistversion=$2" \
23
- | grep -oP 'https://extdist.wmflabs.org/dist/extensions/.*?.tar.gz' \
24
- | head -1
+ url_page=$(curl -s "https://www.mediawiki.org/wiki/Special:ExtensionDistributor?extdistname=$1&extdistversion=$2")
+
+ if [[ "$!" != "0" ]];
25
+ then
26
+ echo $url_page | grep -oP 'https://extdist.wmflabs.org/dist/extensions/.*?.tar.gz' | head -1
27
+ else
28
+ echo "Extension version page download failed. Retrying in 1s."
29
+ sleep 1
30
31
+ fetch_extension_url "$@"
32
+ fi
33
}
34
35
function fetch_skin_url() {
0 commit comments