Skip to content

Edit on Github

Michael Burridge edited this page Mar 26, 2020 · 11 revisions

Editing a documentation file in our gitbook-docs repository is like editing any other file directly on Github.

1. Find the file you want to edit

In any page of the documentation site, you'll find a link (on the right sidebar) that will take you directly to the corresponding file in the repository.

sidebar-right-documentation

You can also browse directly through this repository until you find the file you'd like to edit.

2. Open the document in the online file editor

In the upper right corner of the file view, click the button with the pencil icon, to open the file editor.

github-edit-button

3. Make your changes in the "Edit file" tab

On the Edit file tab, make any changes you want to make to the file.

github-edit-tab

You can preview your changes by clicking "Preview changes". Take into account that the final style will be given by gitbook but it will use the content and markup set in the file.

4. Propose File Change

At the bottom of the page, type a short, meaningful commit message that describes the change, or changes, that you made to the file (For example → Improved expression).

propose-file-change

Below the commit message fields, click the email address drop-down menu and choose a Git author email address.

Below the commit message fields select the option Create a new branch for this commit and start a pull request. This option will create a new branch, you can then create a pull request from there.

When selecting Create a new branch for this commit and start a pull request you can see a default name for the branch is available. You can leave that as it is in order to simplify things, or you can type another name for the branch that you think is more meaningful.

Click "Propose file change".

5. Create Pull Request

Once you click the "Propose file change" you'll be redirected to the "Open a pull request" page.

create-pull-request

Here you can change the title of the pull request (Improved expression in our example) and add any comments regarding your changes, but usually you can just click the "Create pull request" button.

So... click "Create pull request".


🎉 Boom! Pull requested created. Now the ball is in our court.

We will either accept your changes and merge them with the final version or, if we want to discuss the changes, we will start a conversation about your changes on the Pull Request.