SHARE:
Uncategorized

Submitting a Pull Request

Flatiron School / 6 November 2012

The following is a guest post by Kevin Curtin and originally appeared on his blog. Kevin is currently a student a The Flatiron School. You can learn more about him here, or follow him on twitter here.

Last week I talked about the importance of conributing to open source documentation. Here is a quick guide on how to actually go through the process of submitting a pull request and contributing to a project:

1. Fork the repository

Forking the repository will give you a copy of it on your github account

2. Clone your fork to your local machine

Change to the directory you want to store the project in. And run this command:

This just pulls down a copy of the repo onto your machine. Running the clone command will automatically create a new directory in your current working directory with the name of the repo you cloned. In this case, it created a folder called “sqlite3-ruby” in my current directory.

3. Enter the directory and checkout a new branch

Enter the new directory by running:

Branch names should describe the change you are going to make, for example:

4. Make the changes you wanted to and push them to a remote branch

Once you have made changes, add them and commit them. Then run:

This will push your changes to a remote branch so that you can submit your pull request.

5. Submit the pull request!

Once you submit it, you will be asked to describe the change you made. Keep it short and to the point!

Ruby's #each_with_object Previous Post ActiveRecord Without Rails Next Post