...
...
...
...
...
...
...
...
Contributing code to Raxa JSS EMR
We would like more and more people to contribute to our project. Please follow the following guidelines for contributing code, so that it is easier for you as well as us to quickly get your code merged into our repositories.
Although we would like people to contribute code in whichever way they can, it will be really really considerate if instead of attaching patches to tickets, you can fork our github repository and code is submitted through pull requests.
So, you will have to create two ids. Doing this with the same email address is optimal, but not mandatory:
Following are the steps to follow:
- Fork one of our github repos, depending on what code you want to contribute to: https://github.com/raxa/repositories
- Select one of the tickets (OPEN status) for which you want to write code - https://raxaemr.atlassian.net
- Assign yourself to the ticket and ask questions regarding design. If there is no design, please create design diagrams by communicating on the dev list
- Clone your github fork locally (hint: git clone <your fork>)
- Write code (by following Coding Standards) and commit locally with the ticket number as part of your commit message (hint: git commit -m “RAXAJSS-91 - I made something”). This will help automatically linking your work on the ticket after we merge things.
- Change the ticket status to IN PROGRESS
- Push the local commit to your own fork (hint: git push)
Also write something meaningful to the ticket comment about commit to your own fork. That way people are updated that you are working on something and gives early access to other developers. In the lines of
Code Block Changeset: {changeset_id} Author: {author name} Date: {timestamp} Message: {commit_message}
- Make additional commits with the same steps as mentioned 5-7.
- When the work on the ticket is complete, make a pull request (hint: in github.com click on Pull Request). This will create a pull request that core developers can review and merge. If the developer feels the pull request adequately resolves the issue, the ticket status should be changed to RESOLVED
- Code can be reviewed in 2 ways, depending on the complexity of the feature. Core developers should write a summary of their reviews in the ticket comments:
- pre-merge - When pull request is submitted, core developers will review code by looking for changes, running tests etc. This is useful for simple features or code that is not integrating with many components/pages
- post-merge - The pull request is merged by core developers, but reviews are done in crucible (https://raxaemr.atlassian.net/source/cru/) because these involve integration tests, debugging code and checking how things are actually running
- If there are no more code changes required and ticket has been suitably completed along with testing, the core developer who merged the code should change the ticket status to CLOSED
...
Other things to remember
- Merge code changes with the Raxa branch often
- Add the main Raxa respository as an upstream with the read-only link. (for client app repo, hint: git remote add upstream git://github.com/Raxa/Raxa-JSS.git)
- Get the code changes (hint: git fetch upstream)
- Merge with your local fork (hint: git merge upstream/master)
- Push the merged changes to your github fork to be updated (hint: git push)
- Commit code with Unix-style line-endings (default - but usually a configuration when installing git)