Contribution Code - CMPUT301F16T18/Unter GitHub Wiki

Pull Request

All changes to the code in the future should be submitted as a PR, and each PR should be reviewed and tested before being merge to the master branch.

Once the PR is accepted and pass all tests at Travis CI, it would be merged to the master branch.

Contribution Procedure

  1. Fork the repo at https://github.com/CMPUT301F16T18/Unter to your own Github repo.

  2. Make a local clone of your fork on your own computer.
    git clone https://github.com/username/Unter

  3. Add the original repo as new remote.
    git remote add upstream https://github.com/CMPUT301F16T18/Unter

  4. Fetch changes to local.
    git fetch upstream

  5. Checkout back to master.
    git checkout master

  6. If you want your changes in the feature branch to always the latest.
    git rebase upstream/master

  7. if you want to reflect the true ordering of commits.
    git merge upstream/master

  8. After you are done with your work, push the changes to your own fork to Github, and then submit a PR at the team repo.
    git push origin master

Style Guide

Google Java Style Guid

  1. Please follow thoese coding guidlines
  2. Use 4 spaces as indention

Setup

Code Style file for Android Studio

$ wget https://raw.githubusercontent.com/google/styleguide/gh-pages/intellij-java-google-style.xml)
$ cp intellij-java-google-style.xml ~/Library/Preferences/AndroidStudio2.1/codestyles

Go to Preferences -> Editor -> Code Style -> Java, select GoogleStyle

Note

  • Android Studio 2.1.3
  • JDK 1.7.0_79
  • CompiledSdkVersion 23
  • BuildToolsVersion 22.0.1