Send Your Changes for Review
After you have edited documentation, added any new pages, and tested your changes with a local build, you should:
-
Open a pull request (PR) to merge your changes into the live documentation.
Commit and Push Your Changes
Committing your files means that you’re ready for those changes to go to the remote version of your branch in the GitHub repository. Commits group related changes together on a branch. You can group similar changes together in a commit to make it easier to undo changes.
Pushing actually sends your changes to the remote version of your branch in the GitHub repository. Pushing ensures that the changes are safely stored on GitHub, and not just your computer.
It’s a good idea to commit and push regularly to avoid losing your work.
You can commit and push using VS Code, GitHub Desktop, or the command line.
Commit and Push With VS Code
You can view more details in the VS Code Documentation. |
To commit changes and push them to your remote branch from VS Code:
-
Click Source Control.
VS Code should list all of the changes you have made to files in the repository. Click a change entry to view more details.
-
Do one of the following:
-
To prepare to commit a single change, point to the change entry and click + (Stage Changes).
-
To prepare to commit all of your listed changes, point to the Changes heading and click + (Stage All Changes).
If you want to discard any changes, point to the change and click Discard Changes.
-
-
In the text field, write a descriptive commit message. Start your commit message with the ticket number for your changes, surrounded in square brackets. For example,
[AV-000001]
.Try to be descriptive about what you changed so other contributors know what changes were made in your commit. For example,
Changed "server" to "Server" in add-pages.adoc
. -
Click Commit.
-
Click Sync Changes.
Commit and Push with GitHub Desktop
See the documentation on Committing and reviewing changes to your project in GitHub Desktop.
When you’re writing your commit message, start with the ticket number for your changes, surrounded in square brackets.
For example, [AV-000001]
.
Try to be descriptive about what you changed so other contributors know what changes were made in your commit.
For example, Changed "server" to "Server" in add-pages.adoc
.
Commit and Push with the Command Line
To commit changes and push them to your remote branch from the command line:
-
Open a terminal window.
-
Check the changes on your local branch:
$ git status
-
For each file you want to add to your commit, run the following command, filling in the filepath and filename:
$ git add <file-path>/<file-name>
-
Run the following command to add a commit message and commit your changes, filling in a descriptive commit message:
$ git commit -m "<Your-commit-message>"
Start your commit message with the ticket number for your changes, surrounded in square brackets. For example,
[AV-000001]
.Try to be descriptive about what you changed so other contributors know what changes were made in your commit. For example,
Changed "server" to "Server" in add-pages.adoc
. -
Push your changes to the remote version of your branch by running the following command:
$ git push origin <branch-name>
Open a Pull Request for Your Branch
After you have committed and pushed all of the changes you need to make to the documentation files to GitHub, you need to open a pull request (PR).
PRs let other writers review your changes before they get added to the live documentation. They merge the changes from your working branch into a release branch or the main branch in a Documentation repository.
To open a PR for your working branch:
-
Go to the GitHub page for the repository you were working on.
-
In the branch list, select your branch:
-
Go to
. -
In the base list, select the branch you selected as your base branch when you created your working branch.
-
In the Add a title field, enter a descriptive title for your changes.
Start with the ticket number for your changes, surrounded in square brackets. For example,
[AV-000001]
. The rest of your title can be similar to the name of your branch. -
In the Add a description field, enter a more detailed description of the changes you made with your commit or commits.
Make sure to provide enough context that your reviewers know why you made the changes. If you’re making a substantial enough change, make sure to also include a link to your preview site.
-
In the Reviewers section, click the gear icon and add any specific reviewers you need for your PR.
You might need to know their GitHub username.
-
If you’re ready to send a notification to your chosen reviewers, click Create Pull Request.
If you still need more time to make additional changes, but just wanted a quick check on the start of a project, expand Create Pull Request and click Create draft pull request, instead.
Your PR should be reviewed by your chosen reviewers or someone else on the Documentation team within a couple of working days. We greatly appreciate community contributions and do our best to review them promptly.
If you’re a member of the Documentation team, do not forget to share a link to your PR in our review channel on Slack.
Review an Existing Pull Request
To review an existing pull request, use GitHub’s Pull Request Review features:
Incorporate Feedback from a Review
To incorporate feedback from a review of an existing pull request, use GitHub’s Applying Suggested Changes instruction page.
Next Step
After your PR has been reviewed, you can click Merge pull request to merge your changes into your chosen branch.
If you’re a member of the Documentation team, you can choose to build the Couchbase Documentation site to get your changes live right away, or wait for the daily build to publish your changes the next day.
Make sure you delete your branch after you have merged your pull request. This keeps our repositories tidy. |