Skip to content

[Documentation:Developer] Preliminary steps for pushing to a fork #605

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions _docs/developer/getting_started/commit_to_PR_from_fork.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,14 @@ merging to the main branch.

The instructions below are for command line use of git.

1. **Before** you begin, confirm that your local main branch of Submitty is
up-to-date. Additionally, if the PR's branch is not up-to-date with Submitty's main,
there will be a button on its page on Github that you can press to update it.
You may need to resolve merge conflicts in the process of updating it.

![alt text](/images/update-branch.png)

1. First, from the PR on the Github website, find the name of the
2. From the PR on the Github website, find the name of the
user + branch name. It should be formatted something like this:
```
contributorusername:contributor_branch_name
Expand All @@ -31,7 +37,7 @@ The instructions below are for command line use of git.
The `fork_name` may simply be `Submitty`, or the author may have chosen to another name.


2. Next, make a local branch on your computer in your working repository
3. Next, make a local branch on your computer in your working repository
with the proposed code changes. Here are the command lines
(substitute the user, branch, and fork names we found above):

Expand All @@ -48,14 +54,14 @@ The instructions below are for command line use of git.
```


3. This has made a local branch named
4. This has made a local branch named
`contributorusername-contributor_branch_name`. Go ahead and test
and review the PR and make code edits and new commits to your
local branch as needed.



4. In order to push the changes to the contributor's fork (and the PR
5. In order to push the changes to the contributor's fork (and the PR
on Github from the fork), you will specify the upstream to be the
contributor's fork:

Expand Down Expand Up @@ -93,7 +99,7 @@ The instructions below are for command line use of git.
```


5. Now once you are finished with your code changes, first commit them to
6. Now once you are finished with your code changes, first commit them to
the local branch (named
`contributorusername-contributor_branch_name`).

Expand All @@ -106,7 +112,7 @@ The instructions below are for command line use of git.
*NOTE: If you encounter a permissions error, it is possible that the external
contributor didn't grant access for collaboration on the branch.*

6. Confirm that you can see the changes on the Github website for the PR.
7. Confirm that you can see the changes on the Github website for the PR.


---
Expand Down
Binary file added images/update-branch.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading