How to contribute code

GitHub is our primary platform for collaborative software development within the Simpler Grants community. This guide will help you get started and make the most out of your code contribution experience.

Looking for work?

Our development team curates "help wanted" issues for open source developers like you to help out with on GitHub.

Contribution Guidelines

A. Code style and standards

  • Follow the established code style and standards.

  • Use clear and description variable names, comments and documentation where necessary.

B. Testing

  • Write tests for your code changes to ensure they function as expected

  • Run exiting tests and ensure they pass before submitting your pull request

C. Documentation

  • Update any relevant documentation in the README files to reflect changes

Getting Started

1. Create a Fork

Create a new fork of the simpler grants.gov repository for your changes. Fork names should conform to the simpler grants naming convention

For example

Next, create a feature branch using the following command, replacing feature-branch-name with a name that follows our branch naming schema

2. Clone the repository

Clone the forked repository to your local machine using the following command:

Instruction on setting up the local development environment can be found in the README of the repository.

API Development Instructions API Development Instructions

Front End Development Instructions Front End Development Instructions

Need help with your local development environment? Post in the Discourse forum if you're having issues. We can walk you through the process of resolving blockers. We also use a CODEOWNERS file to automatically suggest and add folks knowledgeable about the area of the code you're making changes to.

3. Make & Commit changes

Make your desired changes to the codebase using your preferred editor. Once you're done, stage and commit your changes:

4. Push Changes

  • Push your changes to your forked repository on GitHub using the following command:

5. Run code quality checks to verify changes

Frontend:

On the frontend of the project we enforce formatting, linting, typescript checks and unit testing before a code change can be accepted.

To run frontend tests:

API

In the API of the project we enforce formatting, linting and unit tests. These all must pass before code changes can be accepted.

To run API tests:

6. Create a Pull Request

a. Navigate to your forked repository on GitHub

b. Click on the Pull Request button

c. Fill out the pull request form

d. Validate that GitHub automated integration testing is not failing. If it is go back and make changes to your code until all tests are passing again.

e. Submit the pull request for review by other developers within the community

Example pull request form:

7. Review process

a. Assign reviewers

  • Assign reviewers to your pull request who are knowledgeable about the project and can provide valuable feedback

b. Feedback and iteration

  • Address any feedback or comments from reviewers promptly

  • Make necessary changes and iterate on your code until it meets the projects standard to be accepted

  • Once your pull request has been approved it will be merged into the main branch and deployed as necessary.

Change log

Major updates to the content of this page will be added here.

Date
Update
Notes

2/12/2024

Initial Content

Updated with Initial content

10/3/2024

Updated content

Updated content for hackathon

Last updated

Was this helpful?