Initial setup
If you dont have a github account already then you need to sign up and create one on on github.com (free accounts are fine).
Once you have a github account, the next step is to fork https://github.com/openMF/mifosx or https://github.com/openMF/community-app.git.
See https://help.github.com/articles/fork-a-repo for help on forking in github.
Clone the repository
Create a directory in which you want the cloned project to exist within: e.g. in directory ~/repo
Code Block | ||
---|---|---|
| ||
git clone [fork repository url] |
See https://help.github.com/articles/which-remote-url-should-i-use.
Configure remotes
When a repository is cloned, it has a default remote called origin that points to your fork on GitHub, not the original repository it was forked from. To keep track of the original repository, you should add another remote named upstream:
The easiest way is to use the https url:
Code Block | ||
---|---|---|
| ||
git remote add upstream https://github.com/openMF/[mifosx | community-app].git |
or if you have ssh set up you can use that url instead:
Code Block | ||
---|---|---|
| ||
git remote add upstream git@github.com:openMF/[mifosx | community-app].git |
Keep up to date
There will be development changes to both repositories almost every day for the foreseeable future so its important to keep your fork of the software up to date with the latest changes.
To pull in upstream changes from repository you forked:
Code Block | ||
---|---|---|
| ||
git checkout develop git fetch upstream git merge upstream/develop |
Warning |
---|
You should not have any local changes on your master branch, if you do, use rebase! |
Once you have pulled all latest changes and your build was successful, push the just merged changes to the develop branch on your fork.
Code Block | ||
---|---|---|
| ||
git push origin develop |
Build
After setting up your environment, and downloading the source, refer to the following per-project instructions on how to build:
Mifos X Financial Service Engine
We use Gradle to build the Mifos X Financial Service Engine.
To run a build change into the directory [your project root]/mifosx/mifosng-provider, and execute:
Code Block | ||
---|---|---|
| ||
cd ~/repo/mifosx/mifosng-provider ./gradelw clean build |
This command will download all dependencies, compiles all sources, and executes all unit tests.
To run integration tests make sure you have installed and setup the database, execute:
Code Block | ||
---|---|---|
| ||
./gradelw integrationTest |
Mifos X Community App
Given that the Mifos X Community App is a single page application using AngularJS, there is no real build available.
If you want to start the application, simply follow these stepsgrunt is used to build production ready artefacts:
Code Block | ||
---|---|---|
| ||
cd ~/repo/community-app # Pull run- and build time dependencies bower install npm install # Serve the Create a production ready artefact grunt prod |
For development purposes you can serve the application by simply calling:
Code Block | ||
---|---|---|
| ||
cd ~/repo/community-app
grunt serve |