Code.gov - Unlocking the potential of the Federal Government’s software.
Code.gov is a website promoting good practices in code development, collaboration, and reuse across the U.S. Government. Code.gov provides tools and guidance to help agencies implement the Federal Source Code Policy. It also includes an inventory of government custom code to promote reuse between agencies and provides tools to help government and the public collaborate on open source projects.
To learn more about the project, check out this blog post.
Code.gov is an open source project, so we invite your contributions, be it in the form of code, design, or ideas.
The development of code.gov is guided by the requirements set forth in https://sourcecode.cio.gov/.
For documentation on how to configure code-gov-front-end, go here.
Here’s how you can help contribute to code.gov:
Source Code Policy
- To provide feedback on code-gov-front-end, please checkout our Contributing Guildelines.
- To contribute to the Code.gov style guide, head over to the code-gov-style repo.
- Checkout code-gov for a list of additional project repositories. If you aren't sure where your question or idea fits, this is a good place to share it.
If you have questions, please feel free to send us an email.
After you have cloned this repo, you can use
npm install to install all of the
You can then run the server using
npm run start.
By default, the development server will listen on http://localhost:8080/. You can change the default port by setting the
PORT environment variable before starting the server (for example,
PORT=3000 npm start).
Development of tests is in progress
Read about how to publish to Github pages, Federalist and elsewhere here
Deploying Arbitrary Branch
Specifying an API Key
The app uses the API key provided in the site.json by default.
If you want to override that, specify an
CODE_GOV_API_KEY environmental variable. Here's an example:
CODE_GOV_API_KEY=l87sfdi7ybc2bic7bai8cb2i176c3b872tb3 npm run start
Generating License Data
To update the
dependency_licenses.json file, run
npm run licenses.
The directories in
src are organized around the pillars of React, along
with several additional custom file types. When creating new files, be sure to
add your file and any necessary templates, styles, and tests to a directory
dedicated to your new file in the appropriate place.
We've moved the bulk of the CSS for this application into a Style Guide repository so that we can more easily keep things consistent and deploy changes more quickly.
You'll need to clone/download the Style Guide repository to get started.
If you need to make CSS changes, make them within this directory and commit them to that repository.
For more instructions on how to make changes, view the readme inside of the Style Guide repository.
As stated in CONTRIBUTING:
[..] this project is in the worldwide public domain (in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication).
All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.