Wikimedia Developer Support

Help for volunteers to start contributing

This topic is for any questions to help you contributing to MediaWiki.

If you don’t get answers here, there are some volunteers and quite some operators on the MediaWiki discord as well who might be able to help.

From T240254#6235059:

! In T240254#6235059, @Abhir-24 wrote:
Is there any way to get the output when the changes are made in any file

If I understand your question correctly:
Set $wgResourceLoaderDebug = true; in LocalSettings.php then load the page in browser, open DevTools, inspect the element, see the CSS rules, there will be a link to the stylesheet where those rules are. That will show you the generated CSS.

and also how to determine which .less file belongs to #page-secondary-actions

It’s helpful to note that this is about the MinervaNeue skin. Usually styles are in the resources folder, but Minerva has a lot in others too.
Run a full-text search for *.less files in the MinervaNeue folder with your dev tool (I suggest VS Code, but I use Notepad++ and TotalCommander for speed :wink: ) or grep if you’re on linux. You’ll find 3 .less files.

and the parent #content part in file skin.mustache since there are a lot of folders containing the styling files?

Search for .mw-body in the *.less files as above. The rules are defined for the class of that element.
Alternatively, look at the style rules in DevTools.

@Aron_Manning I am copying the file path of LocalSettings.php and running it in the browser but it is not loading I tried loading the page with some VS code extensions like PHP server but the page is not loadind. Can u pls tell the format to load the pages since I don’t know PHP much. I googled to understand but I am not getting anything to solve my query.

Look at https://www.mediawiki.org/wiki/Download_from_Git for a guide installing mediawiki in your webserver. It’ll guide you to configure the URL that will serve mediawiki. Usually http://localhost/wiki.
Restart the server, visit that URL, an installer will help you configure your mediawiki.
After that’s finished you’ll reach your mediawiki instance at http://localhost/wiki/Main_Page
You won’t need to add LocalSettings.php in the URL, that’s loaded by mediawiki. Write the page title into the URL, as if you were browsing wikipedia.

This is the default path IIRC. The exact URL and path can be different depending on how you configure it.

I have installed the mediawiki but I am not able to understand as to how should I set up the server for Minervaneue using mediawiki because a mediawiki folder is only installed after I went through https://www.mediawiki.org/wiki/Download_from_Git and when I am trying to run http://localhost/wiki after adding that folder name or any file name then also it is showing requested URL not found.

Clone Minerva too with git into the core/skins/MinervaNeue folder from: https://gerrit.wikimedia.org/g/mediawiki/skins/MinervaNeue/+/master/

Add these 2 lines to your core/LocalSettings.php:
https://www.mediawiki.org/wiki/Skin:Minerva_Neue#Installation

Then see steps 3-4 in https://www.mediawiki.org/wiki/Manual:Installation_guide#Manual_installation
You’ll need to configure your Apache (I guess) to know where your mediawiki is installed. Please look for Apache guides on the internet. I’ve added the following to my httpd.conf, but your values will be different:

Alias  /w/  "X:/dev/mw/core/"
Alias  /  "X:/dev/mw/core/index.php/"
<Directory "X:/dev/mw/core">
    Options FollowSymLinks Includes
    AllowOverride All
    Require all granted
    #Allow from all
</Directory>

If you get stuck, join the MediaWiki discord (https://discord.gg/ZrV2Ex9), you’ll get help there to get it running.

This “Help for volunteers to start contributing” topic should not exist as it is not a topic by definition. If at all, it should be a category instead. Now it’s a catch-all for anything so nobody will be able to find anything and in consequence we could get rid of all and any topics and instead only have one single topic for everything and anything.