Getting started with Open Source Software

Being up-to-date and avoiding conflicts

Have you ever wondered how you could collaborate with open-source projects but you didn’t know how to start? It couldn’t be easier. Take a look:

  • Fork the repository into your account.
  • Clone the forked project on your computer.
  • Add the upstream to sync with the new changes to your project.
# If you run `git remote -v` you should see:
origin (fetch)
origin (push)
upstream (fetch)
upstream (push)

Get the last changes in your project (not necessary if you just forked the project).

  • Create a new branch.
  • Once you are done, let’s create a PR!
  • If you get errors trying to push your last changes, add your SSH credentials.

That’s all!

If your changes (or someone else’s) have been merged in the origin, you need to run fetch upstream master and git merge upstream/master in master to be up-to-date!

To sum up

# Get all changes from sync project into upstream branch
git fetch upstream master
# Merge upstream branch into your current branch
git merge upstream/master

Competitive, entrepreneur and autodidact. Hard worker, lover of technology and free software.