Developer Guide: Contributing¶
Git Workflow¶
For all repositories in the EarthquakeHub suite, the following guidelines are used for developer contributions. However, make sure to also check the CONTRIBUTING.md of the specific repository you’re contributing to.
1. Create a branch from the repository’s deployment baseline¶
Do not assume that every repository uses the same deployment branch. Check the repository’s remote default branch and deployment workflow before creating a feature branch. In the current UPRI EarthquakeHub workspace, the documentation repository uses main, while the service repositories used by the deployment workflow use dev.
For a service repository whose baseline is dev, create a new branch from dev:
git checkout -b feature/new-feature
2. Commit & Push¶
Commit your changes with a descriptive commit message then push to upstream. Please refer to the following tags as guide in naming your commit messages and pull request titles:
draft - to be completed PR/commit
feat - new feature
fix - bug fixes
test - anything related to testing
chore - (aka housekeeping) cleaning/styling/refactor code, adding comments
docs - anything related to documentation / comments
3. Create a Pull Request¶
Navigate to UPRI-earthquake’s GitHub repository and switch to the new branch. Click the “New Pull Request” button. Be sure to follow the pull request template for each repository and the Pull Request Title format: type: [TASK ID] SHORTENED TASK TITLE
4. Review & Merge¶
Another team member will be assigned to review your pull request and to provide feedback if necessary. Once the changes you have made are approved, they will be merged into the dev branch. Final testing will be done before the new-feature is added into the main branch and deployed to the online servers.