Contributing to Public Lab Software
Public Lab welcomes and encourages community contributions to our open source software!
This page is intended to:
- List software projects that Public Lab has incubated and provide links to source code.
- Collect software development guidelines and best practices for Public Lab projects.
- Help newcomers figure out how and where to start contributing!
For an excellent overview of contributing to open source projects in general, check out How to contribute to an open source project on Github.
Quick tips for getting involved with the Public Lab codebases:
Set up a GitHub account and install git.
If you're not familiar with git, a popular version control software, you can try it out at https://try.github.io.
Speaking of GitHub...right now, all of Public Lab's open source code is located on GitHub, a website which hosts git repositories. Setting up a GitHub account is the first step to getting involved with Public Lab's code (and lots of other code).
Public Lab software is written in many languages, and each project may have its own guidelines for contributors. These broad guidelines should serve as general principles to guide your approach to a new Public Lab codebase.
If this is your first time contributing to open source software, or to Public Lab, see our Welcome page to take your first step!
Also check out this article on GitHub flow, a routine that works great on all git projects and makes Public Lab development super smooth.
|Can I get a file of numbers instead of a graph from the foldable spectrometer software?||@mountevans||almost 4 years ago||1||4|
|Software project ideas for upcoming 2018 Summer of Code fellowships?||@warren||almost 4 years ago||7||9|
|Create a welcoming "first-timers-only" issue to invite new software contributors||-||-||@warren||-||-||0 replications: Try it »|
|Github guide for Open Source Contributions||-||-||@stefannibrasil||-||-||0 replications: Try it »|
|Help Public Lab’s software grow by joining a supportive team||-||-||@warren||-||-||0 replications: Try it »|
|Use Git and GitHub to contribute and improve Public Lab software||-||-||@warren||-||-||0 replications: Try it »|
|Set up your development environment in Cloud9||-||-||@liz||-||-||0 replications: Try it »|
|Make the most basic github contribution||-||-||@liz||-||-||0 replications: Try it »|
Activities should include a materials list, costs and a step-by-step guide to construction with photos. Learn what makes a good activity here.
A sample git workflow
See this activity for a guide to using branches and pull requests on GitHub.
For some additional tips for different scenarios, such as if you've forgotten to make your commits in a named feature branch and need to rewind your main, see below
Public Lab Software
For an overview of Public Lab software projects, see this list on the Developers page
Rewinding the main branch
Sometimes you forget to make your commits on a named feature branch, and add commits to your main branch. You want to rewind the main branch back so you can pull in the latest changes from others, but you don't want to lose your work! It's all right, though -- you can follow these steps to rewind, update, and rebase your changes on top of the latest commits to Public Lab's main branch (shown here for the
git checkout main- go back to your main branch (your work is saved in the feature branch)
git reset --hard 123456-- rewind your main branch to a state before it diverged from our main (where
123456is the commit hash just before your commits -- the latest one your history has in common with the publiclab/plots repository's history)
git pull https://github.com/publiclab/plots2.git main-- fetch publiclab's latest main
git checkout feature-branch-name-- go back to your saved feature branch, named something more descriptive than
git rebase main-- this just detaches your latest changes (minus the deleted one) and reattaches or "replays" them onto the latest main. If you see merge errors, try following this guide to resolve them.
git push origin feature-branch-name-- push up your newly re-based changes! (you can use
git push -f origin feature-branch-nameforces, to overwrite a PR if you've already opened one)
- Go to https://github.com/publiclab/plots2 to look for the prompt to open a PR if you haven't already.