diff --git a/.gitignore b/.gitignore index 72f7657..26519ba 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ -composer -mediawiki -.envrc -conf \ No newline at end of file +/composer-setup.php +/composer +/mediawiki +/.envrc +/conf diff --git a/LocalSettings.php b/LocalSettings.php index 9a929a6..4893162 100644 --- a/LocalSettings.php +++ b/LocalSettings.php @@ -1,95 +1,100 @@ load(); $env = $_ENV; } $ret = $default; if ( isset( $env[$key] ) ) { $ret = $env[$key]; } if ( $ret === null ) { echo "Please set the envvar $key.\n"; exit( 10 ); } if ( $splitOn !== null ) { $ret = explode( $splitOn, $ret ); } return $ret; }; +if ( php_sapi_name() === 'cli' ) { + $wgDebugLogFile = 'php://stderr'; +} else { + $wgDebugLogFile = $getSetting( "MW_DEBUG_LOG", false ); +} $wgShowExceptionDetails = true; $wgDebugDumpSql = true; error_reporting( -1 ); ini_set( 'display_startup_errors', 1 ); ini_set( 'display_errors', 1 ); if ( substr( strtoupper( $getSetting( "DEBUG", "N" ) ), 0, 1 ) === "N" ) { $wgShowExceptionDetails = false; $wgDebugDumpSql = true; error_reporting( 0 ); ini_set( 'display_startup_errors', 0 ); ini_set( 'display_errors', 0 ); } $wgSitename = $getSetting( "MW_SITENAME" ); $wgMetaNamespace = $getSetting( "MW_META_NAMESPACE", str_replace( " ", "_", ucfirst( $wgSitename ) ) ); $wgScriptPath = $getSetting( "MW_SCRIPT_PATH", "/w" ); $wgResourceBasePath = $getSetting( "MW_RESOURCE_BASE_PATH", $wgScriptPath ); $wgArticlePath = $getSetting( "MW_ARTICLE_PATH", '/wiki/$1' ); $wgServer = $getSetting( "MW_SERVER", false ); $wgLogo = $getSetting( "MW_LOGO", "{$wgScriptPath}/resources/assets/wiki.png" ); $wgEmergencyContact = $getSetting( "MW_EMERGENCY_CONTACT" ); $wgPasswordSender = $getSetting( "MW_PASSWORD_SENDER", $wgEmergencyContact ); $wgCachePrefix = $getSetting( 'MW_CACHE_PREFIX', false ); $wgDBtype = $getSetting( "MW_DB_TYPE", "mysql" ); $wgDBserver = $getSetting( "MW_DB_SERVER" ); $wgDBname = $getSetting( "MW_DB_NAME" ); $wgDBuser = $getSetting( "MW_DB_USER" ); $wgDBpassword = $getSetting( "MW_DB_PASSWORD" ); $wgDBprefix = $getSetting( "MW_DB_PREFIX", "" ); $wgCookiePrefix = $getSetting( "COOKIE_PREFIX", false ); $wgCookieDomain = $getSetting( "COOKIE_DOMAIN", "" ); $wgDBTableOptions = $getSetting( "MW_DB_TABLE_OPTIONS", "ENGINE=InnoDB, DEFAULT CHARSET=binary" ); $wgMemCachedServers = $getSetting( "MW_MEM_CACHED_SERVERS", "localhost:11211", "|" ); $wgShellLocale = $getSetting( "MW_SHELL_LOCALE", "C.UTF-8" ); $wgLanguageCode = $getSetting( "MW_LANGUAGE_CODE", "en" ); $wgExtensionDirectory = __DIR__ . "/extensions"; $wgStyleDirectory = __DIR__ . "/skins"; $wgSessionCacheType = $wgMessageCacheType = $wgParserCacheType = $wgMainCacheType = $wgSessionCacheType = CACHE_MEMCACHED; $wgSessionsInObjectCache = true; $wgMemCachedPersistent = true; $wgUsePathInfo = true; $localSettingsDir = __DIR__ . "/LocalSettings.d"; if ( is_dir( $localSettingsDir ) ) { $dir = new DirectoryIterator( $localSettingsDir ); $order = []; foreach ( $dir as $file ) { $name = $file->getPathname(); if ( !$file->isDot() && $file->isReadable() && substr( $name, -4 ) === ".php" ) { $order[] = $name; } } sort( $order ); foreach ( $order as $file ) { require $file; } } unset( $localSettingsDir ); unset( $getSetting ); diff --git a/Makefile b/Makefile index 52e9eed..ed4b059 100644 --- a/Makefile +++ b/Makefile @@ -1,158 +1,316 @@ include makeutil/baseConfig.mk - -.PHONY: checkForCommand -checkForCommand: - type ${cmd} > /dev/null 2>&1 || ( echo ${cmd} is not installed; exit 10 ) - -.PHONY: git -git: cmd=git -git: checkForCommand - -.PHONY: direnv -direnv: cmd=direnv -direnv: checkForCommand +include commands.mk +include extensions.mk +include $(shell echo local.m*k | grep \\.mk$$) # makeutil/baseConfig.mk: git test -f $@ || \ - git clone "https://phabricator.nichework.com/source/makefile-skeleton" makeutil + ${git} clone "https://phabricator.nichework.com/source/makefile-skeleton" makeutil + +# Gerrit URL +gerritHead ?= https://gerrit.wikimedia.org/r # Git repo to use for cloning -mwGitURL ?= https://gerrit.wikimedia.org/r/mediawiki/core.git +mwGitURL ?= ${gerritHead}/mediawiki/core.git # MediaWiki branch or version to clone mwBranch ?= REL1_34 # ifndef VERBOSE verboseUpdatePhp=-q else verboseUpdatePhp= endif # -targets ?= vendor composer.local.json composer.lock extensions skins LocalSettings.php +targets ?= vendor composer.lock extensions skins LocalSettings.php .PHONY: mediawiki # Check out or update mediawiki mediawiki: git direnv echo ${indent} Set up mediawiki for symlink in ${targets}; do \ echo ${indent} Checking $$symlink && \ test ! -L mediawiki/$$symlink || ( \ rm -f mediawiki/$$symlink ) && \ test ! -e conf/$$symlink || ( \ test ! -d mediawiki/$$symlink || ( \ echo mediawiki/$$symlink exists!;exit 1 ) && \ mv conf/$$symlink mediawiki ) ; \ done - test -e $@/.git || \ - git clone --recurse-submodules --branch ${mwBranch} ${mwGitURL} $@ && ( \ + test -e $@/.git || ( \ + echo Extracting mediawiki branch "<${mwBranch}>" from git... && \ + ${git} clone --recurse-submodules --branch ${mwBranch} \ + ${mwGitURL} $@ ) && ( \ + echo Updating mediawiki branch "<${mwBranch}>"... && \ cd $@ && \ - cur=`git rev-parse --abbrev-ref HEAD` && \ - git checkout . && \ - git pull --recurse-submodules && \ + cur=`${git} rev-parse --abbrev-ref HEAD` && \ + ${git} checkout . && \ + ${git} pull --recurse-submodules && \ test "$$cur" = "${mwBranch}" || ( \ - git branch -l | grep -q '^ .${mwBranch}$$' || \ - git checkout -b "${mwBranch}" "origin/${mwBranch}" && \ - git checkout --recurse-submodules "${mwBranch}" ) \ + echo Switching from "<$$cur>" to the "<${mwBranch}>" branch... && \ + ${git} branch -l | grep -q '^ .${mwBranch}$$' || \ + ${git} checkout -b "${mwBranch}" "origin/${mwBranch}" && \ + ${git} checkout --recurse-submodules "${mwBranch}" ) \ ) + ${make} verifyMWINSTALL ${make} conf/LocalSettings.php ${make} conf/composer.local.json ${make} conf/composer.lock ${make} conf/extensions ${make} conf/skins ${make} conf/vendor ${make} installExtensions ${make} updatePhp # .PHONY: ensureDirAndFile ensureDirAndFile: test -n "${dir}" || ( \ echo dir should be defined. && \ exit 1 ) test -n "${file}" || ( \ echo file should be defined. && \ exit 1 ) .PHONY: symlinkConf symlinkConf: ensureDirAndFile echo ${indent} $@ for ${file} test -L ${dir}/${file} || ( \ rm -f ${dir}/${file} && \ ln -s ../conf/${file} ${dir}/${file} ) # conf: mkdir -p $@/LocalSettings.d .PHONY: conf/LocalSettings.php conf/LocalSettings.php: conf test -f $@ || cp LocalSettings.php $@ ${make} symlinkConf dir=mediawiki file=LocalSettings.php .PHONY: conf/composer.local.json -conf/composer.local.json: conf +conf/composer.local.json: conf/LocalSettings.php test ! -L mediawiki/composer.local.json -a -f mediawiki/composer.local.json && \ mv mediawiki/composer.local.json $@ || true ${make} symlinkConf dir=mediawiki file=composer.local.json - test -f $@ || echo '{}' | jq '. + {require: { "vlucas/phpdotenv": "~4"}}' > $@ + export json="`cat $@ 2>/dev/null| jq -rM . 2>/dev/null`" || true && \ + test -n "$$json" || \ + json='{}' && \ + echo $$json | jq '.require += { "vlucas/phpdotenv": "~4" }' | sponge $@ .PHONY: conf/composer.lock -conf/composer.lock: conf +conf/composer.lock: conf/composer.local.json test ! -L mediawiki/composer.lock -a -f mediawiki/composer.lock && \ mv mediawiki/composer.lock $@ || true ${make} symlinkConf dir=mediawiki file=composer.lock - test -f $@ || echo '{}' > $@ + test -f $@ || ${make} composerInstall .PHONY: conf/extensions conf/extensions: conf test -L mediawiki/extensions -o ! -d mediawiki/extensions || ( \ test ! -d $@ || rm -rf $@ && \ mv mediawiki/extensions $@ ) ${make} symlinkConf dir=mediawiki file=extensions test -d $@ || mkdir -p $@ .PHONY: conf/skins conf/skins: conf test -L mediawiki/skins -o ! -d mediawiki/skins || ( \ test ! -d $@ || rm -rf $@ && \ mv mediawiki/skins $@ ) ${make} symlinkConf dir=mediawiki file=skins test -d $@ || mkdir -p $@ .PHONY: conf/vendor conf/vendor: conf test -L mediawiki/vendor -o ! -d mediawiki/vendor || ( \ test ! -d $@ || rm -rf $@ && \ mv mediawiki/vendor $@ ) ${make} symlinkConf dir=mediawiki file=vendor test -d $@ || mkdir -p $@ .PHONY: installExtensions installExtensions: - for ext in ${selectedExtensions} ; do \ - echo Installing $$ext ; \ - done + echo ${selectedExtensions} | sed 's, ,\n,g' | xargs -i{} ${make} install-ext-{} -.PHONY: updatePhp -updatePhp: composerUpdate dbVerify${MW_DB_TYPE} +.PHONY: verifyMWINSTALL +verifyMWINSTALL: test -f ${MW_INSTALL_PATH}/maintenance/update.php || ( \ - echo Please set MW_INSTALL_PATH! && \ - exit 1 ) + echo Please set MW_INSTALL_PATH! MW_INSTALL_PATH is currently && \ + echo ${MW_INSTALL_PATH} and maintenance/update.php is not there! && \ + echo && exit 1 ) + +.PHONY: updatePhp +updatePhp: composerUpdate dbVerify${MW_DB_TYPE} verifyMWINSTALL ${php} ${MW_INSTALL_PATH}/maintenance/update.php ${verboseUpdatePhp} --quick +.PHONY: composerInstall +composerInstall: composer + export pwd=`pwd` && \ + cd ${MW_INSTALL_PATH} && ${php} $$pwd/composer install + .PHONY: composerUpdate -composerUpdate: composer +composerUpdate: composer verifyMWINSTALL export pwd=`pwd` && \ cd ${MW_INSTALL_PATH} && ${php} $$pwd/composer update +.PHONY: dbVerify dbVerify: echo Please set MW_DB_TYPE! exit 1 +.PHONY: dbVerifypercona dbVerifypercona: dbVerifymysql +.PHONY: dbVerifymysql dbVerifymysql: - php -r 'if ( !function_exists( "mysqli_connect" ) ) { echo "Please install mysql extension for php.\n"; exit(1); }' + ${php} -r 'if ( !function_exists( "mysqli_connect" ) ) { echo "Please install mysql extension for php.\n"; exit(1);}' + +.PHONY: install-ext-% +install-ext-%: + export name=$(subst install-ext-,,$@) && \ + test -d mediawiki/extensions/$$name -a \ + -f conf/LocalSettings.d/extension-$$name.php || ( \ + echo installing $$name && \ + ${make} extension-$$name ) && ( \ + echo $$name is installed ) + +.PHONY: extension-% +extension-%: + ${make} install-extension branch=${mwBranch} \ + name=$(subst extension-,,$@) \ + repo=${gerritHead}/mediawiki/extensions/$(subst extension-,,$@) + +# Fetch an extension for mediawiki and enable it +.PHONY: install-extension +install-extension: stem=extension +install-extension: loc=conf/extensions/${name} +install-extension: enableStem + +# Install and enable an extension using require_once +.PHONY: legacy-extension +legacy-extension: + test -f ${lsDir}/${stem}-${name}.php || ( \ + ( echo ' ${lsDir}/${stem}-${name}.php ) + ${make} install-extension branch=${mwBranch} \ + name=${name} \ + repo=${gerritHead}/mediawiki/extensions/${name} + +# Install an extension using composer +.PHONY: install-composer-extension +install-composer-extension: ${compLocalJson} jq sponge + echo ${indent}Installing ${stem} "${name}" + ${make} install-extension tag=${tag} branch=${branch} name=${name} \ + repo=${repo} + + echo ${indent}updating composer.local.json for ${stem} "${name}" + jq '.["require"]["${compID}"]="${compVer}"' ${compLocalJson} | \ + sponge ${compLocalJson} + rm -f composerUpdateNotNeeded + +# +.PHONY: enableStem +enableStem: verifyName updateRepo + echo ${indent}$@ for ${name} ${stem} + ${make} LocalSettingsAddWf name=${name} stem=${stem} + +.PHONY: verifyStem +verifyStem: + test -n "${stem}" || ( \ + echo "Choose a stem!"; \ + exit 1 ) + +.PHONY: verifyName +verifyName: verifyStem + test -n "${name}" || ( \ + echo A name must be specified for this ${stem}!; \ + exit 1 ) + +ensureRemoteOrigin: verifyNameAndRepo + echo ${indent}$@ for ${repo} at ${loc} + + export origin=`cd ${loc} && ${git} remote get-url origin` && \ + test -z "$$origin" -a "$$origin" = "${repo}" || ( \ + echo ${indent}Updating remote for the ${name} ${stem}.; \ + cd ${loc} && ${git} remote set-url origin ${repo} ) + +.PHONY: updateRepo +updateRepo: verifyName checkoutAndLinkGit ensureRemoteOrigin + test ! -n "${tag}" -o ! -n "${branch}" || ( \ + echo -n Do not specify both tag \(${tag}\) and branch; \ + echo " "\(${branch}\) for ${name}! && \ + exit 1 \ + ) + + echo ${indent}Updating repo for ${name} + ( \ + cd ${loc} && ${git} reset --hard && ${git} status -s | \ + awk '/^\?\?/ {print $2}' | xargs rm -rf; \ + ${git} fetch origin; \ + ) + + ${make} maybeEnsureBranch branch=${branch} stem=${stem} name=${name} \ + loc=${loc} + + ${make} maybeEnsureTag tag=${tag} stem=${stem} name=${name} \ + loc=${loc} + + echo ${indent}Handling any submodules + cd ${loc} && ${git} submodule update --init --recursive + +.PHONY: checkoutAndLinkGit +checkoutAndLinkGit: verifyNameAndRepo + echo ${indent}Handling the ${name} ${stem} + + ${make} doClone linkLoc=${linkLoc} loc=conf/${stem}s/${name} \ + name=${name} stem=${stem} repo=${repo} + ${make} maybeUpdateSubmodules loc=conf/${stem}s/${name} + +verifyNameAndRepo: verifyName + test -n "${repo}" || ( \ + echo "No git repo given for ${name}!" && \ + exit 1 ) + +doClone: + test ! -n "${DESTRUCTIVE}" -o ! -d conf/${stem}s/${name} || \ + rm -rf conf/${stem}s/${name} + echo ${indent}Cloning ${name} into ${stem}s && \ + ${git} submodule add -f ${repo} conf/${stem}s/${name} + +maybeUpdateSubmodules: + # Add any submodules + test ! -e ${loc}/.gitmodules || ( \ + cd ${loc} && ${git} ${gitSsl} submodule update --init ) + +.PHONY: maybeEnsureBranch +maybeEnsureBranch: + test -z "${branch}" || ( \ + echo ${indent}Ensuring ${name} ${stem} is on ${branch} && \ + cd ${loc} && ${git} fetch && \ + test $$(${git} branch | awk '/^\*/ {print $$2}') = "${branch}"|| \ + ${git} ${gitSsl} checkout ${branch} ) + +.PHONY: maybeEnsureTag +maybeEnsureTag: + test -z "${tag}" || ( \ + echo ${indent}Ensuring ${name} is on the tag ${tag}; \ + cd ${loc} && ${git} ${gitSsl} fetch && \ + ${git} checkout ${tag} \ + ) + +.PHONY: LocalSettingsAddWf +LocalSettingsAddWf: verifyName LocalSettings.php + echo ${indent}$@ for ${stem} ${name} + + test -d "${lsDir}" || \ + mkdir -p ${lsDir} + + # Lucky us, PHP is case-insensitive for function names, so we + # call wfLoadskin() and wfLoadextension() + test -f ${lsDir}/${stem}-${name}.php || ( \ + ( echo ' ${lsDir}/${stem}-${name}.php ) diff --git a/commands.mk b/commands.mk new file mode 100644 index 0000000..c2a04b3 --- /dev/null +++ b/commands.mk @@ -0,0 +1,25 @@ +.PHONY: checkForCommand +checkForCommand: + type ${cmd} > /dev/null 2>&1 || ( echo ${cmd} is not installed; exit 10 ) + +php ?= php +.PHONY: php +php: cmd=${php} +php: checkForCommand + +git ?= git +.PHONY: git +git: cmd=${git} +git: checkForCommand + +.PHONY: direnv +direnv: cmd=direnv +direnv: checkForCommand + +.PHONY: sponge +sponge: cmd=sponge +sponge: checkForCommand + +.PHONY: jq +jq: cmd=jq +jq: checkForCommand diff --git a/extensions.mk b/extensions.mk new file mode 100644 index 0000000..080dd61 --- /dev/null +++ b/extensions.mk @@ -0,0 +1,172 @@ +make ?= ${MAKE} -f $(abspath $(firstword $(MAKEFILE_LIST))) indent="${indent}\> " + +.PHONY: extension-UserFunctions +extension-UserFunctions: name=UserFunctions +extension-UserFunctions: stem=extension +extension-UserFunctions: legacy-extension + +.PHONY: extension-PerconaDB +extension-PerconaDB: name=PerconaDB +extension-PerconaDB: repo=https://github.com/MWStake/PerconaDB +extension-PerconaDB: stem=extension +extension-PerconaDB: branch=master +extension-PerconaDB: tag= +extension-PerconaDB: compID=mediawiki/percona-db +extension-PerconaDB: compVer=dev-master +extension-PerconaDB: + ${make} install-composer-extension name=${name} repo=${repo} tag=${tag} \ + stem=${stem} branch=${branch} compID=${compID} compVer=${compVer} + +.PHONY: extension-HeaderFooter +extension-HeaderFooter: + ${make} enableStem name=HeaderFooter branch=master stem=extension \ + repo=https://github.com/jamesmontalvo3/MediaWiki-HeaderFooter.git loc=conf/extensions/HeaderFooter + +.PHONY: extension-SuggestedTitles +extension-SuggestedTitles: + ${make} enableStem name=SuggestedTitles branch=master stem=extension \ + repo=https://phabricator.nichework.com/source/SuggestedTitles.git loc=conf/extensions/SuggestedTitles + +.PHONY: extension-IFrame +extension-IFrame: + ${make} enableStem name=IFrame branch=master stem=extension \ + repo=https://github.com/hexmode/mediawiki-iframe.git loc=conf/extensions/IFrame + +.PHONY: extension-ViewProtect +extension-ViewProtect: + ${make} enableStem name=ViewProtect branch=master stem=extension \ + repo=https://github.com/hexmode/mediawiki-ViewProtect loc=conf/extensions/ViewProtect + +.PHONY: extension-SimpleBatchUpload +extension-SimpleBatchUpload: name=SimpleBatchUpload +extension-SimpleBatchUpload: repo=https://github.com/s7eph4n/SimpleBatchUpload +extension-SimpleBatchUpload: stem=extension +extension-SimpleBatchUpload: branch= +extension-SimpleBatchUpload: tag=${simpleUploadVer} +extension-SimpleBatchUpload: compID=mediawiki/simple-batch-upload +extension-SimpleBatchUpload: compVer=${simpleUploadVer} +extension-SimpleBatchUpload: + test -n "${simpleUploadVer}" || ( \ + echo "Please set simpleUploadVer!"; \ + exit 2; \ + ) + ${make} install-composer-extension name=${name} repo=${repo} tag=${tag} \ + stem=${stem} branch=${branch} compID=${compID} compVer=${compVer} + +.PHONY: extension-SemanticWatchlist +extension-SemanticWatchlist: name=SemanticWatchlist +extension-SemanticWatchlist: repo=https://github.com/SemanticMediaWiki/SemanticWatchlist +extension-SemanticWatchlist: stem=extension +extension-SemanticWatchlist: branch= +extension-SemanticWatchlist: tag=${semWatchVer} +extension-SemanticWatchlist: compID=mediawiki/semantic-watchlist +extension-SemanticWatchlist: compVer=${semWatchVer} +extension-SemanticWatchlist: + test -n "${semWatchVer}" || ( \ + echo "Please set semWatchVer!"; \ + exit 2; \ + ) + test -f ${lsDir}/${stem}-${name}.php || ( \ + ( echo ' ${lsDir}/${stem}-${name}.php ) + ${make} install-composer-extension name=${name} repo=${repo} tag=${tag} \ + stem=${stem} branch=${branch} compID=${compID} compVer=${compVer} + +.PHONY: extension-SemanticGlossary +extension-SemanticGlossary: name=SemanticGlossary +extension-SemanticGlossary: repo=https://github.com/SemanticMediaWiki/SemanticGlossary +extension-SemanticGlossary: stem=extension +extension-SemanticGlossary: branch= +extension-SemanticGlossary: tag=${semGlossVer} +extension-SemanticGlossary: compID=mediawiki/semantic-glossary +extension-SemanticGlossary: compVer=${semGlossVer} +extension-SemanticGlossary: + test -n "${semGlossVer}" || ( \ + echo "Please set semGlossVer!"; \ + exit 2; \ + ) + test -f ${lsDir}/${stem}-Lingo.php || ( \ + ( echo ' ${lsDir}/${stem}-Lingo.php ) + ${make} extension-Lingo + ${make} install-composer-extension name=${name} repo=${repo} tag=${tag} \ + stem=${stem} branch=${branch} compID=${compID} compVer=${compVer} + +.PHONY: extension-Lingo +extension-Lingo: name=Lingo +extension-Lingo: stem=extension +extension-Lingo: branch= +extension-Lingo: tag=${lingoVer} +extension-Lingo: compID=mediawiki/lingo +extension-Lingo: compVer=${lingoVer} +extension-Lingo: + test -n "${lingoVer}" || ( \ + echo "Please set lingoVer!"; \ + exit 2; \ + ) + ${make} install-composer-extension name=${name} tag=${tag} \ + stem=${stem} branch=${branch} compID=${compID} compVer=${compVer} \ + repo=${gerritHead}/mediawiki/extensions/${name} + +.PHONY: extension-SemanticMediaWiki +extension-SemanticMediaWiki: name=SemanticMediaWiki +extension-SemanticMediaWiki: repo=https://github.com/SemanticMediaWiki/SemanticMediaWiki +extension-SemanticMediaWiki: stem=extension +extension-SemanticMediaWiki: branch= +extension-SemanticMediaWiki: tag=${smwVer} +extension-SemanticMediaWiki: compID=mediawiki/semantic-media-wiki +extension-SemanticMediaWiki: compVer=${smwVer} +extension-SemanticMediaWiki: + test -n "${smwVer}" || ( \ + echo "Please set smwVer!"; \ + exit 2; \ + ) + test -n "${smwDomain}" || ( \ + echo "Please set smwDomain!"; \ + exit 2; \ + ) + test -f ${lsDir}/${stem}-${name}.php || ( \ + ( echo ' ${lsDir}/${stem}-${name}.php ) + ${make} install-composer-extension name=${name} repo=${repo} tag=${tag} \ + stem=${stem} branch=${branch} compID=${compID} compVer=${compVer} + +.PHONY: extension-GEUser +extension-GEUser: + ${make} enableStem name=GEUser stem=extension loc=conf/extensions/GEUser branch=master \ + repo=git@github.build.ge.com:KnowledgeSharing/wiki-GEUser.git + +.PHONY: extension-GEBranding +extension-GEBranding: + ${make} enableStem name=GEBranding stem=extension loc=conf/extensions/GEBranding branch=master \ + repo=git@github.build.ge.com:KnowledgeSharing/wiki-GEBranding.git + +.PHONY: extension-DynamicPageList +extension-DynamicPageList: + ${make} enableStem name=DynamicPageList stem=extension loc=conf/extensions/DynamicPageList tag=3.3.3 \ + repo=https://gitlab.com/hydrawiki/extensions/DynamicPageList.git + +.PHONY: extension-NamespaceManager +extension-NamespaceManager: + ${make} enableStem name=NamespaceManager stem=extension loc=conf/extensions/NamespaceManager branch=master \ + repo=https://github.com/hexmode/mediawiki-NamespaceManager + +.PHONY: extension-Elastica +extension-Elastica: name=Elastica +extension-Elastica: stem=extension +extension-Elastica: cmJS=conf/composer.local.json +extension-Elastica: sponge + export json="`cat ${cmJS} 2>/dev/null| jq -rM . 2>/dev/null`" || true && \ + echo $$json | jq '.extra."merge-plugin".include += [ "extensions/Elastica/composer.json" ]' | sponge ${cmJS} + ${make} install-extension branch=${mwBranch} name=${name} \ + repo=${gerritHead}/mediawiki/extensions/${name} + +.PHONY: extension-CirrusSearch +extension-CirrusSearch: name=CirrusSearch +extension-CirrusSearch: stem=extension +extension-CirrusSearch: cmJS=conf/composer.local.json +extension-CirrusSearch: sponge + export json="`cat ${cmJS} 2>/dev/null| jq -rM . 2>/dev/null`" || true && \ + echo $$json | jq '.extra."merge-plugin".include += [ "extensions/CirrusSearch/composer.json" ]' | sponge ${cmJS} + ${make} install-extension branch=${mwBranch} name=${name} \ + repo=${gerritHead}/mediawiki/extensions/${name} diff --git a/makeutil b/makeutil index e5c1ae6..b8cefac 160000 --- a/makeutil +++ b/makeutil @@ -1 +1 @@ -Subproject commit e5c1ae6ce5b833d69997bf1613bd0a205b20a60d +Subproject commit b8cefacef868384eb4df848f131b922607b4aa45