Contribute on GitHub
Prerequisites
If you are new to GitHub, you will first need to sign up for a GitHub account.
We also encourage you to complete self-paced GitHub learning courses for brushing up on basic GitHub skills.
Let's get started!
This documentation is written in Markdown format and is based on the Material for MkDocs theme, which is built on top of MkDocs static site generator.
For a quick reference on how to use Markdown syntax you can refer to the Markdown Cheat Sheet.
Raise a GitHub Issue
All contributions need to have an associated GitHub issue that explains the content and importance of the contribution.
To raise an issue, create a New Issue in the ACCESS-Hive Docs GitHub repository issue page. Feel free to assign that issue to yourself if you intend to work on it.
Fork the ACCESS-Hive Docs GitHub repository
After raising a GitHub issue about your contribution, you need to fork the ACCESS-Hive Docs GitHub repository.
Clone the forked ACCESS-Hive Docs GitHub repository locally
For cloning the forked repository onto your local computer, we encourage you to first add your local SSH keys to your GitHub profile.
To start with, if you have an existing SSH key, then simply add this key to your github account, and you are all set to clone the repository. In case you don't have the SSH keys set up on your local computer, it's easy to create a new SSH key locally, and then feel free to link this key to your github account.
Make changes locally
After cloning the repository locally, create a new branch to make your local changes and then push it to GitHub:
Work locally on the branch spongebob/fix-hive-title-issue-234
, and push the commits using the commands:
While working on a local branch, please make sure to regularly pull changes from the remote main
into your local branch, as follows:
This would make sure that the local branch spongebob/fix-hive-title-issue-234
is always in sync with the latest changes in the remote main
branch.
Deploying Website Preview
MkDocs includes a live preview server, so you can preview your changes as you write your documentation. The server will automatically rebuild the site upon saving.
To build the site locally, you need to install Material for MkDocs and other plugins. You can find a full list in the requirements.txt
file (in the root of the ACCESS-Hive Docs GitHub repository). Please use pip
for the installation as some of the packages are not updated or not available on conda:
To start the server, open terminal and navigate to your ACCESS-Hive Docs local repository and use the command:
Your documentation will be built on http://127.0.0.1:8000. Open this URL in your browser to see a preview of the documentation. The URL is given in the terminal when running the mkdocs serve
command. Make sure you keep the command running so as to see live updates on saving your modifications.
Create a Pull Request for the final changes
Once the changes on your local branch spongebob/fix-hive-title-issue-234
are ready to be integrated with the development
branch, create a pull request and GitHub will automatically build a preview of the documentation using GitHub Actions.
After a PR is created and tested, feel free to ask for reviews by tagging the ACCESS-NRI/WebOps team and reply if any changes are being requested in the PR.