This repository was archived by the owner on Sep 23, 2023. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -362,6 +362,7 @@ function set_progress( float $pc, string $label ) {
362362 'SERVER ' => $ server ,
363363 'SERVERPATH ' => $ serverPath ,
364364 'LANGUAGE ' => $ language ,
365+ 'REPOSITORIES ' => $ reposString ,
365366 ]
366367);
367368if ( $ error ) {
@@ -384,6 +385,7 @@ function set_progress( float $pc, string $label ) {
384385 'MAINPAGE ' => $ mainPage ,
385386 'USE_PROXY ' => $ useProxy ,
386387 'USE_INSTANT_COMMONS ' => $ useInstantCommons ,
388+ 'REPOSITORIES ' => $ reposString ,
387389 ]
388390);
389391if ( $ error ) {
Original file line number Diff line number Diff line change @@ -22,12 +22,10 @@ cat $PATCHDEMO/localsettings/core.txt >> $PATCHDEMO/wikis/$NAME/w/LocalSettings.
2222while IFS=' ' read -r repo dir; do
2323 filename=$( echo $repo | sed " s/\//-/g" | sed " s/^mediawiki-//" )
2424 if [ -f $PATCHDEMO /localsettings/$filename .txt ]; then
25- if [ -d $PATCHDEMO /wikis/$NAME /$dir ]; then
26- echo -e " \n// $repo " >> $PATCHDEMO /wikis/$NAME /w/LocalSettings.php
27- cat $PATCHDEMO /localsettings/$filename .txt >> $PATCHDEMO /wikis/$NAME /w/LocalSettings.php
28- fi
25+ echo -e " \n// $repo " >> $PATCHDEMO /wikis/$NAME /w/LocalSettings.php
26+ cat $PATCHDEMO /localsettings/$filename .txt >> $PATCHDEMO /wikis/$NAME /w/LocalSettings.php
2927 fi
30- done < $PATCHDEMO /repository-lists/all.txt
28+ done <<< " $REPOSITORIES "
3129
3230# create htaccess
3331echo " RewriteEngine On
Original file line number Diff line number Diff line change 4242# import extension/skin/service-specific XML dumps
4343while IFS=' ' read -r repo dir; do
4444 filename=$( echo $repo | sed " s/\//-/g" | sed " s/^mediawiki-//" )
45- if [ -d $PATCHDEMO /wikis/$NAME /$dir ]; then
46- # matches extension-foo.xml or extension-foo-*.xml
47- for page in $( find $PATCHDEMO /pages -regextype egrep -regex " .*/$filename (-.+)?.xml" -not -type d -printf ' %P\n' )
48- do
49- echo " Importing $PATCHDEMO /pages/$page "
50- php $PATCHDEMO /wikis/$NAME /w/maintenance/importDump.php < $PATCHDEMO /pages/$page
51- done
52- fi
53- done < $PATCHDEMO /repository-lists/all.txt
45+ # matches extension-foo.xml or extension-foo-*.xml
46+ for page in $( find $PATCHDEMO /pages -regextype egrep -regex " .*/$filename (-.+)?.xml" -not -type d -printf ' %P\n' )
47+ do
48+ echo " Importing $PATCHDEMO /pages/$page "
49+ php $PATCHDEMO /wikis/$NAME /w/maintenance/importDump.php < $PATCHDEMO /pages/$page
50+ done
51+ done <<< " $REPOSITORIES"
5452
5553# import generic XML dumps (core-*.xml)
5654for page in $( find $PATCHDEMO /pages -name " core-*.xml" -not -type d -printf ' %P\n' )
You can’t perform that action at this time.
0 commit comments