Actions

Difference between revisions of "Developer Area/Developer Tools"

From Mahara Wiki

< Developer Area
(→‎Setting up your development tools: no advertising of proprietary web browsers!)
(17 intermediate revisions by the same user not shown)
Line 1: Line 1:
 +
This page describes the software and web accounts that you'll to [[Developer Area/Contributing Code|contribute code]] to Mahara.
 +
 
= Setting up your development tools =
 
= Setting up your development tools =
  
 
NOTE: Before you get started, you need to decide on which email address you will be using while developing on Mahara. This will make sure all the different tools know who you are when they are sharing information about the project.
 
NOTE: Before you get started, you need to decide on which email address you will be using while developing on Mahara. This will make sure all the different tools know who you are when they are sharing information about the project.
  
If you are using the '''Cookie Pie Firefox plugin''', sadly you will need to '''disable''' this. The plugin interferes with the code review web application.
+
==Locally installed tools==
  
<div style="clear:both; width:96%; background-color:#eee; float:left;padding:1% 2% 2% 2%;margin-top:30px;">
+
These are tools that need to be installed locally on the development machine.
    <div style="float:left; width:45%; margin-right:5%;">
 
        <div style="text-align:center;">
 
<!--
 
  
 +
===Git Version Control System===
  
 +
If you plan to submit code changes will need to set up a local git repository, and you'll need the git software for this.
  
 +
If you are running Ubuntu, this is done by:
  
 +
sudo apt-get install git
  
 +
On Debian:
  
# As the name says, these are tools used via a remote website.
+
sudo apt-get install git-core
  
-->
+
On Fedora, you will need to (with root privileges) do:
            <h3>Web based tools</h3>
 
        </div>
 
        <div style="background-color:white;border-top:3px solid #666;border-bottom:1px solid #999;padding:20px;">
 
<!--
 
  
# CONTENT FOR THE WEB TOOLS BLOCK STARTS HERE
+
yum install git-core
  
-->
+
(if this didn't work, check to see if [http://fedoraproject.org/wiki/Extras the extras repository] is enabled. Though this could be a sign your Fedora is a really old version and you might need to update.
Mahara development uses several web-based tools for workflow. You will need to sign up at each of them and give them certain information so that your work is attributed to you throughout.
 
  
<h4>Launchpad.net</h4>
+
On windows, you should download an installer from [http://git-scm.com/download the git website.]
  
The [https://bugs.launchpad.net/mahara Mahara bug tracker] is on launchpad.net.  
+
Once you have git installed, you'll need to configure it with the name and email address to put on your commits. (You should use the same email address as in your user profile for all the web tools.)
  
This means that to use the bug tracking workflow you will need to [https://launchpad.net/+login sign up for a launchpad.net account]. If you already have a launchpad account, you can skip ahead to the next step.
+
git config --global user.name "FirstName LastName"
 +
git config --global user.email "user@example.com"
  
<h4>Gitorious.org</h4>
+
By default git will use the command-line text editor "nano" whenever it needs you to enter some text. If you'd rather use a different editor, you can change that by setting the "core.editor" setting. If you're unfamiliar with the command line, you may want to use "gedit" the default Ubuntu text editor:
  
Mahara's code tree is hosted on gitorious.org. If you have already signed up with launchpad, gitorious accepts your launchpad url (which is openid) [https://gitorious.org/login for logins (look under the heading text)]. If you don't already have an account, or an openid url, please [https://gitorious.org/users/new register an account].
+
git config --global core.editor "gedit --standalone --wait"
  
Please make sure that you have the same email address registered to both launchpad and gitorious.
+
(Gedit needs the "standalone" and "wait" flags to be compatible as a git text editor.)
  
<h4>Gerrit code review (reviews.mahara.org)</h4>
+
===xmllint===
  
All code changes to Mahara go through a code review process. This is hosted at reviews.mahara.org and uses the launchpad openid for signin.
+
In order to use the Mahara project's gerrit convenience scripts, you'll need to install xmllint. In Ubuntu or debian, the process should be:
  
To create your account on the [https://reviews.mahara.org/ Mahara code review system] (which uses [http://code.google.com/p/gerrit Gerrit Code Review]):
+
sudo apt-get install libxml2-utils
  
# install the [http://wiki.cacert.org/BrowserClients CAcert root certificate] in your browser
+
===Secure Shell (SSH) Key===
# '''uninstall''' the Cookie Pie Firefox extension if you have it. It will prevent you from logging in.
 
# click the "Sign In" in the top right corner of the page
 
# enter your preferred OpenID (we recommend using Launchpad: https://launchpad.net/~username)
 
# click the "Settings" in the top right corner of the page
 
# add these details:
 
#* username (hint: use the one you use on mahara.org, '''all lowercase''')
 
#* full name
 
#* email address(es)
 
#* ssh key (hint: use the one you use on gitorious)
 
  
Previous documentation mentioned the 'mahara reviewers' group. You do '''not''' need direct commit or to be part of the 'mahara reviewers' group to send your patchsets through the gerrit system.
+
You'll need to create an SSH key pair, so that you can later upload the '''public''' key to reviews.mahara.org. There are several excellent guides to this process on the Internet, including the one from [https://help.github.com/articles/generating-ssh-keys/ GitHub].
  
<h4>Mahara.org</h4>
+
== Web based tools ==
  
Lastly! You should sign up at mahara.org!
+
Mahara development uses several web-based tools for workflow. You will need to sign up at each of them and give them certain information so that your work is attributed to you throughout.
  
<!--
+
===Launchpad.net===
  
# CONTENT FOR THE WEB TOOLS BLOCK ENDS HERE
+
The [https://bugs.launchpad.net/mahara Mahara bug tracker] is on launchpad.net.
  
-->
+
This means that to use the bug tracking workflow you will need to [https://launchpad.net/+login sign up for a launchpad.net account]. If you already have a launchpad account, you can skip ahead to the next step.
        </div>
 
    </div>
 
    <div style="float:right; width:45%; margin-left:4%;">
 
        <div style="text-align:center;">
 
<!--
 
  
 +
===Gerrit code review (reviews.mahara.org)===
  
 +
All code changes to Mahara go through a code review process. This is hosted at reviews.mahara.org and uses the Launchpad OpenId for sign-in.
  
 +
To create your account on the [https://reviews.mahara.org/ Mahara code review system] (which uses [http://code.google.com/p/gerrit Gerrit Code Review]):
  
 +
# Click the "Sign In" in the top right corner of the page
 +
# Enter your preferred OpenID (we recommend using Launchpad: https://launchpad.net/~username)
 +
# Click the "Settings" in the top right corner of the page
 +
# Add these details:
 +
#* Username (hint: '''All lowercase'''. It's easiest if this matches your username on your local machine.)
 +
#* Full name
 +
#* Email address(es)
 +
#* SSH public key (hint: the one [https://wiki.mahara.org/index.php/Developer_Area/Developer_Tools#Secure_Shell_.28SSH.29_Key we just told you to create])
  
 +
(Previous documentation mentioned the "mahara reviewers" group. You do '''not''' need direct commit or to be part of the 'mahara reviewers' group to send your patchsets through the gerrit system.)
  
# And these are tools that need to be installed locally on the development machine.
+
===Mahara.org===
 
 
-->
 
            <h3>Locally installed tools</h3>
 
        </div>
 
        <div style="background-color:white;border-top:3px solid #666;border-bottom:1px solid #999;padding:20px;">
 
<!--
 
 
 
# CONTENT FOR THE LOCAL TOOLS BLOCK STARTS HERE
 
 
 
-->
 
<h4>Git Version Control System</h4>
 
If you plan to submit code changes will need to set up a local git repository, and you'll need the git software for this.
 
 
 
If you are running Ubuntu or Debian, this is done by:
 
 
 
sudo apt-get install git-core
 
 
 
On Fedora, you will need to (with root privileges) do:
 
 
 
yum install git-core
 
 
 
(if this didn't work, check to see if [http://fedoraproject.org/wiki/Extras the extras repository] is enabled. Though this could be a sign your Fedora is a really old version and you might need to update.
 
 
 
On windows, you should download an installer from [http://git-scm.com/download the git website.]
 
 
 
Once you have git installed, please set your name locally with:
 
 
 
git config --global user.name "FirstName LastName"
 
 
 
And you will also need to set your email. This should be the same email that is in your user profile for all the web tools.
 
 
 
git config --global user.email "[email protected]"
 
 
 
<h4>Secure Shell (SSH) Key</h4>
 
 
 
Please refer to the excellent guide for setting up your key on [https://help.launchpad.net/YourAccount/CreatingAnSSHKeyPair the launchpad.net site]. You will need to give them your key anyway:
 
 
 
<pre>https://launchpad.net/~<YOUR-LAUNCHPAD-USERNAME-GOES-HERE>/+editsshkeys</pre>
 
 
 
You will also need to add the key to your Gitorious profile:
 
 
 
  <pre>https://gitorious.org/~<YOUR-GITORIOUS-USERNAME-GOES-HERE>/keys</pre>
 
 
 
<!--
 
  
# CONTENT FOR THE LOCAL TOOLS BLOCK ENDS HERE
+
While not strictly required for development purposes, it's also recommended that you sign up for an account at mahara.org, in order to participate in the community forums there.
  
-->
+
===wiki.mahara.org===
        </div>
 
    </div>
 
  
</div>
+
If you wish to edit the Mahara wiki, you can log in using your username and password from your mahara.org account.

Revision as of 15:03, 2 September 2016

This page describes the software and web accounts that you'll to contribute code to Mahara.

Setting up your development tools

NOTE: Before you get started, you need to decide on which email address you will be using while developing on Mahara. This will make sure all the different tools know who you are when they are sharing information about the project.

Locally installed tools

These are tools that need to be installed locally on the development machine.

Git Version Control System

If you plan to submit code changes will need to set up a local git repository, and you'll need the git software for this.

If you are running Ubuntu, this is done by:

sudo apt-get install git

On Debian:

sudo apt-get install git-core

On Fedora, you will need to (with root privileges) do:

yum install git-core

(if this didn't work, check to see if the extras repository is enabled. Though this could be a sign your Fedora is a really old version and you might need to update.

On windows, you should download an installer from the git website.

Once you have git installed, you'll need to configure it with the name and email address to put on your commits. (You should use the same email address as in your user profile for all the web tools.)

git config --global user.name "FirstName LastName"
git config --global user.email "[email protected]"

By default git will use the command-line text editor "nano" whenever it needs you to enter some text. If you'd rather use a different editor, you can change that by setting the "core.editor" setting. If you're unfamiliar with the command line, you may want to use "gedit" the default Ubuntu text editor:

git config --global core.editor "gedit --standalone --wait"

(Gedit needs the "standalone" and "wait" flags to be compatible as a git text editor.)

xmllint

In order to use the Mahara project's gerrit convenience scripts, you'll need to install xmllint. In Ubuntu or debian, the process should be:

sudo apt-get install libxml2-utils

Secure Shell (SSH) Key

You'll need to create an SSH key pair, so that you can later upload the public key to reviews.mahara.org. There are several excellent guides to this process on the Internet, including the one from GitHub.

Web based tools

Mahara development uses several web-based tools for workflow. You will need to sign up at each of them and give them certain information so that your work is attributed to you throughout.

Launchpad.net

The Mahara bug tracker is on launchpad.net.

This means that to use the bug tracking workflow you will need to sign up for a launchpad.net account. If you already have a launchpad account, you can skip ahead to the next step.

Gerrit code review (reviews.mahara.org)

All code changes to Mahara go through a code review process. This is hosted at reviews.mahara.org and uses the Launchpad OpenId for sign-in.

To create your account on the Mahara code review system (which uses Gerrit Code Review):

  1. Click the "Sign In" in the top right corner of the page
  2. Enter your preferred OpenID (we recommend using Launchpad: https://launchpad.net/~username)
  3. Click the "Settings" in the top right corner of the page
  4. Add these details:
    • Username (hint: All lowercase. It's easiest if this matches your username on your local machine.)
    • Full name
    • Email address(es)
    • SSH public key (hint: the one we just told you to create)

(Previous documentation mentioned the "mahara reviewers" group. You do not need direct commit or to be part of the 'mahara reviewers' group to send your patchsets through the gerrit system.)

Mahara.org

While not strictly required for development purposes, it's also recommended that you sign up for an account at mahara.org, in order to participate in the community forums there.

wiki.mahara.org

If you wish to edit the Mahara wiki, you can log in using your username and password from your mahara.org account.