This repository was archived by the owner on Sep 23, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +12
-14
lines changed Expand file tree Collapse file tree 3 files changed +12
-14
lines changed Original file line number Diff line number Diff line change @@ -362,6 +362,7 @@ function set_progress( float $pc, string $label ) {
362
362
'SERVER ' => $ server ,
363
363
'SERVERPATH ' => $ serverPath ,
364
364
'LANGUAGE ' => $ language ,
365
+ 'REPOSITORIES ' => $ reposString ,
365
366
]
366
367
);
367
368
if ( $ error ) {
@@ -384,6 +385,7 @@ function set_progress( float $pc, string $label ) {
384
385
'MAINPAGE ' => $ mainPage ,
385
386
'USE_PROXY ' => $ useProxy ,
386
387
'USE_INSTANT_COMMONS ' => $ useInstantCommons ,
388
+ 'REPOSITORIES ' => $ reposString ,
387
389
]
388
390
);
389
391
if ( $ 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.
22
22
while IFS=' ' read -r repo dir; do
23
23
filename=$( echo $repo | sed " s/\//-/g" | sed " s/^mediawiki-//" )
24
24
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
29
27
fi
30
- done < $PATCHDEMO /repository-lists/all.txt
28
+ done <<< " $REPOSITORIES "
31
29
32
30
# create htaccess
33
31
echo " RewriteEngine On
Original file line number Diff line number Diff line change 42
42
# import extension/skin/service-specific XML dumps
43
43
while IFS=' ' read -r repo dir; do
44
44
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"
54
52
55
53
# import generic XML dumps (core-*.xml)
56
54
for 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