Hackathon/Laptop setup/OSX MediaWiki
Get MediaWiki via git
In a terminal, type these commands. This clones the latest development code on MediaWiki into your wiki directory.
git clone https://gerrit.wikimedia.org/r/p/mediawiki/core.git /Applications/MAMP/htdocs/wiki
This will take a while. As it downloads, introduce yourself to a neighbor!
Switch to a different branch of the code
Rather than run whatever is the latest code that has been added to the MediaWiki repository, we encourage you to run a released version of MediaWiki. To do that, run this in the terminal:
cd /Applications/MAMP/htdocs/wiki git checkout origin/REL1_19 -b mywiki
This creates a branch called mywiki based on the MediaWiki 1.19 release, and switches you to that branch. (If that seems like gobbledygook, that is okay for now.)
Make a shortcut in your home directory
For convenience, if you have a directory where you usually put software development projects, you can create a "symbolic link" so that you can access the wiki from there. This makes the wiki code easier to find.
For example, if you normally store your work in a "projects" folder within your home directory, type these commands in a terminal.
First, switch back to your home directory with this command
Then, cd into your projects directory:
(If this complains that there is no such file or directory, run the following command: mkdir projects)
Finally, create the link:
ln -s /Applications/MAMP/htdocs/wiki wiki
Now you can access the wiki via $HOME/projects/wiki/.
Set up the wiki
With the wiki code in place, now is a good time to perform an installation of the wiki. This step is the easiest.
- Visit http://localhost:8888/wiki/ in a web browser.
- Make sure a Continue button appears at the end. Click it!
- The installer will ask you which Database type you want. Choose SQLite.
- Choose whatever you want for the following options:
- Name of wiki (Suggestion: "Mywiki")
- Your name
- Password again
- E-mail address
- Check the box labeled "I'm bored already", then click Continue.
- Click Continue once more, to install the wiki!
- Click Continue yet once more, for some reason.
- The web app will offer you a LocalSettings.php file. The browser will ask you where you want to save it. Navigate to /Applications/MAMP/htdocs/wiki and save the file there.
Make sure your wiki works
If all went well, now when you go to http://localhost:8888/wiki/ , you will see a friendly message that tells you:
MediaWiki has been successfully installed.
Congratulations! Log in with the username you just created to make sure it works.
If something did not work, do ask a staff member for help!