|
1 |
| -# Contributing Guide for the Modular Documentation Project |
| 1 | +# Contributor's guide for the Modular Documentation Project |
2 | 2 |
|
3 |
| -## Request GitHub Project Access |
| 3 | +## Getting started |
4 | 4 |
|
5 |
| -Send an email to the Modular Documentation Project mailing list ([email protected]) asking nicely to be given access to the Modular Documentation Project on GitHub. Please give us your GitHub username and use the following subject line: REQUESTING ACCESS. |
| 5 | +### Request project access |
6 | 6 |
|
7 |
| -## Configuring a Local Copy of the GitHub Project |
| 7 | +To join the Modular Documentation Project, email `[email protected]` with "REQUESTING ACCESS" in the subject and your GitHub username in the body. |
8 | 8 |
|
9 |
| -STEP 1 - Fork your own copy of redhat-documentation/modular-docs: |
10 |
| - |
| 9 | +### Set up your workspace |
11 | 10 |
|
12 |
| -STEP 2 - Go to your fork and copy the SSH link. |
13 |
| - |
| 11 | +#### Fork the repository |
14 | 12 |
|
15 |
| -STEP 3 - In a terminal, clone your fork: |
| 13 | +1. **Fork** the [Modular Docs Repository](https://github.com/redhat-documentation/modular-docs) on GitHub. For more information, see GitHub's [Forking a repository](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo#forking-a-repository) topic. |
16 | 14 |
|
17 |
| - git clone [email protected]:_<username>_/modular-docs.git |
| 15 | +#### Clone your fork |
18 | 16 |
|
19 |
| -STEP 4 - Copy the SSH link of redhat-documentation/modular-docs, not your fork, and set it as your upstream remote: |
| 17 | +2. **Clone** your fork to your local machine: |
20 | 18 |
|
21 |
| - cd modular-docs |
22 |
| - git remote add upstream [email protected]:redhat-documentation/modular-docs.git |
| 19 | + ```bash |
| 20 | + git clone [email protected]: <username >/modular-docs.git |
| 21 | + ``` |
23 | 22 |
|
24 |
| -STEP 5 - Verify that you have two remotes, `origin` and `upstream` and check the status of your project: |
| 23 | + For more information, see GitHub's [Cloning your forked repository](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo#cloning-your-forked-repository) topic. |
25 | 24 |
|
26 |
| - git remote -v |
27 |
| - git status |
| 25 | +#### Configure an upstream remote |
28 | 26 |
|
29 |
| -## Contributing Changes |
| 27 | +3. **Configure an upstream remote** to sync with the original repository: |
30 | 28 |
|
31 |
| -STEP 1 - Create a new branch: |
| 29 | + ```bash |
| 30 | + cd modular-docs |
| 31 | + git remote add upstream [email protected]:redhat-documentation/modular-docs.git |
| 32 | + ``` |
32 | 33 |
|
33 |
| - git checkout -b <new_branch_name> |
| 34 | + For more information, see GitHub's [Configuring git to sync your fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo#configuring-git-to-sync-your-fork-with-the-upstream-repository) topic. |
34 | 35 |
|
35 |
| -Example: |
| 36 | +#### Verify the remotes |
36 | 37 |
|
37 |
| - git checkout -b new_edits |
| 38 | +4. **Verify the remotes** and check your project's status: |
38 | 39 |
|
39 |
| -STEP 2 - Add content or make edits. |
| 40 | + ```bash |
| 41 | + git remote -v |
| 42 | + git status |
| 43 | + ``` |
40 | 44 |
|
41 |
| -STEP 3 - Add and commit your changes: |
| 45 | + The output should look like this: |
42 | 46 |
|
43 |
| - git add <path_to_file> |
44 |
| - git commit -m "<place_your_comments_here>" |
| 47 | + ``` |
| 48 | + origin https://github.com/<username>/modular-docs.git (fetch) |
| 49 | + origin https://github.com/<username>/modular-docs.git (push) |
| 50 | + upstream https://github.com/redhat-documentation/modular-docs.git (fetch) |
| 51 | + upstream https://github.com/redhat-documentation/modular-docs.git (push) |
| 52 | + On branch main |
| 53 | + Your branch is up to date with 'origin/main'. |
45 | 54 |
|
46 |
| - Example: |
| 55 | + nothing to commit, working tree clean |
| 56 | + ``` |
47 | 57 |
|
48 |
| - git add modular-doc-manual/master.adoc |
49 |
| - git commit -m -s "Updated the master.adoc file" |
| 58 | +## Making contributions |
50 | 59 |
|
51 |
| -STEP 4 - Push changes to the remote GitHub repository: |
| 60 | +### Stay updated |
52 | 61 |
|
53 |
| - git push origin <new_branch_name> |
| 62 | +* **Prepare your main branch**: |
54 | 63 |
|
55 |
| -Example: |
| 64 | + ```bash |
| 65 | + git checkout main |
| 66 | + git fetch upstream main |
| 67 | + git rebase upstream/main |
| 68 | + git switch -c <new_branch_name> |
| 69 | + ``` |
56 | 70 |
|
57 |
| - git push origin new_edits |
| 71 | + Example: |
58 | 72 |
|
59 |
| -STEP 5 - Create a new pull request from the GitHub web interface. |
| 73 | + ```bash |
| 74 | + git switch -c create_master_adoc |
| 75 | + ``` |
60 | 76 |
|
61 |
| -STEP 6 - Everyone on the project team will review the merge request and add comments in GitHub. This review process will be open for one week from the day the merge request was submitted. If the merge request is still being actively discussed beyond the one week timeframe, then the merge request will stay open. Once the merge request discussion is resolved, the merge request will be NACK'd or ACK'd based on the comments given. If no comments are given after a week, then the merge request will be ACK'd. |
| 77 | +### Make your changes |
| 78 | + |
| 79 | +1. **Edit content** or add new material as needed. |
| 80 | + |
| 81 | +2. **Stage, commit, and push** your updates: |
| 82 | + |
| 83 | + ```bash |
| 84 | + git add <path_to_file> |
| 85 | + git commit -m "<your_commit_message_here>" |
| 86 | + git push origin HEAD |
| 87 | + ``` |
| 88 | + |
| 89 | + Example: |
| 90 | + |
| 91 | + ```bash |
| 92 | + git add modular-doc-manual/master.adoc |
| 93 | + git commit -m "Updated the master.adoc file" |
| 94 | + git push origin HEAD |
| 95 | + ``` |
| 96 | + |
| 97 | +4. **Create a pull request** by opening the link in the command output. |
| 98 | + |
| 99 | + Example: |
| 100 | + |
| 101 | + ```bash |
| 102 | + remote: Create a pull request for '<new_branch_name>' on GitHub by visiting: |
| 103 | + remote: https://github.com/rolfedh/modular-docs/pull/new/<new_branch_name> |
| 104 | + ``` |
| 105 | + |
| 106 | +### Requesting a team review for your PR |
| 107 | + |
| 108 | + 1. **Initiate a review** by adding `fcc-review-board` under *Reviewers* in the PR and posting a request in [#ccs-mod-docs-steering-committee](https://redhat.enterprise.slack.com/archives/C04QRCA35K8) (private) or [#forum-ccs-mod-docs](https://redhat.enterprise.slack.com/archives/C04RPJLJJ9E) (public) on Slack. |
| 109 | + |
| 110 | + 2. **Engage with feedback** and resolve any issues or suggestions raised by reviewers. |
| 111 | + |
| 112 | + 3. **Follow up**, if needed, by gently reminding reviewers or reposting to the Slack channel after you make significant changes. |
| 113 | + |
| 114 | + 4. **Close the issue**: After your PR gains the necessary approvals and a review board member has merged it, close the issue associated with your PR. |
0 commit comments