| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
MDAnalysis is a free and open source project. It evolves and grows with the demands of its user base. Therefore, the development team very much welcomes contributions from its users. Contributions can take many forms, for instance
Maybe you have a useful new feature for MDAnalysis (for instance, you wrote a specialized analysis task for a paper and now, as the paper has been accepted, you want to share the code) or a fix for a bug or a performance improvement. How can you get this code into the public version of MDAnalysis so that other users can also benefit from your code (and possibly cite you...)?
The typical approach for getting code into MDAnalysis follows a simple protocol:
Clone the MDAnalysis source. Distributed development with git describes in more detail how to do this.
Add your changes to your own fork of MDAnalysis. Push the changes so that they show up in the clone. (Also note the section on Test cases below.)
File a pull request on the Pull requests tracker.
(For more information on how to do pull request ("PR") on GitHub see the help on using pull requests.)
Monitor your issue report for additional questions or suggestions (e.g. by starring it and setting your preferences so that email is sent to you when changes occur).
A developer will then review your code and likely incorporate it into mainline MDAnalysis by merging the changes from your clone.
Once your changes have been added, we will
If you prefer to not be listed then we will certainly honor your preference.
Note that by pulling your changes, the source code itself is still associated with your name: Anyone looking at the source will be able to see that this was your contribution to this open source project.
Please feel free to ask questions on the developer mailing list.
Whenever you contribute a new feature or fix/enhance existing code then you should create an appropriate test case (also known as UnitTests) that exercises your code. This is very important because
Test-driven development is actually a very good way to write code: You first write your test case and while development you repeatedly run your tests until they pass.
UnitTests has more information on the testing framework. However, you might also want to look at existing test cases (all to be found in testsuite/MDAnalysisTests) to get an idea how to structure your test cases.
All code should be accompanied with test cases. We strive for coverage >85% (ideally >90%).
If possible, re-use the existing data files in MDAnalysis (see MDAnalysisTests.datafiles and the files in the directory testsuite/MDAnalysisTests/data) for tests; this helps to keep the (separate) MDAnaltsisTests package small. If new files are required (e.g. for a new coordinate Reader/Writer) then
Make sure that your test case runs and that all other test cases are still passing.
| Back | FazBrowse Home | New Git URL |