Skip to content

[Documentation:Developer] Account for changed name of fork #604

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 3 commits into from
May 28, 2024
Merged
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
25 changes: 14 additions & 11 deletions _docs/developer/getting_started/commit_to_PR_from_fork.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,26 +22,29 @@ The instructions below are for command line use of git.


1. First, from the PR on the Github website, find the name of the
fork + branch name. It should be formatted something like this:
user + branch name. It should be formatted something like this:
```
contributorusername:contributor_branch_name
```

Additionally, find the name of the fork on the fork's page on Github.
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
with the proposed code changes. Here are the command lines
(substitute the fork & branch name we found above):
with the proposed code changes. Here are the command lines
(substitute the user, branch, and fork names we found above):

If you **are not** using ssh keys on git:
```
git checkout -b contributorusername-contributor_branch_name main
git pull https://github.com/contributorusername/Submitty.git contributor_branch_name
git pull https://github.com/contributorusername/fork_name.git contributor_branch_name
```

If you **are** using ssh keys on git:
```
git checkout -b contributorusername-contributor_branch_name main
git pull [email protected]:contributorusername/Submitty.git contributor_branch_name
git pull [email protected]:contributorusername/fork_name.git contributor_branch_name
```


Expand All @@ -58,13 +61,13 @@ The instructions below are for command line use of git.

If you **are not** using ssh keys on git:
```
git remote add upstream https://github.com/contributorusername/Submitty.git
git remote add upstream https://github.com/contributorusername/fork_name.git
```


If you **are** using ssh keys on git:
```
git remote add upstream [email protected]:contributorusername/Submitty.git
git remote add upstream [email protected]:contributorusername/fork_name.git
```


Expand All @@ -77,16 +80,16 @@ The instructions below are for command line use of git.
```
origin https://github.com/Submitty/Submitty.git (fetch)
origin https://github.com/Submitty/Submitty.git (push)
upstream https://github.com/contributorusername/Submitty.git (fetch)
upstream https://github.com/contributorusername/Submitty.git (push)
upstream https://github.com/contributorusername/fork_name.git (fetch)
upstream https://github.com/contributorusername/fork_name.git (push)
```

Or this if you **are** using ssh keys on git:
```
origin [email protected]:Submitty/Submitty.git (fetch)
origin [email protected]:Submitty/Submitty.git (push)
upstream [email protected]:contributorusername/Submitty.git (fetch)
upstream [email protected]:contributorusername/Submitty.git (push)
upstream [email protected]:contributorusername/fork_name.git (fetch)
upstream [email protected]:contributorusername/fork_name.git (push)
```


Expand Down
Loading