Skip to content

Commit

Permalink
#43 Adds in a section in 7 conflicts on comparing diffs across branch…
Browse files Browse the repository at this point in the history
…es via GitHub
  • Loading branch information
astroDimitrios authored Jan 10, 2025
1 parent 6bbf005 commit f3af3ed
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions episodes/06-conflict.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,26 @@ The far left shows how long ago the commit was that changed those lines.
Then the commit message is displayed before the file contents.
Click on the little page icon after a commit message to see previous
commits which altered the same lines.
Try using blame on the `CITATION.cff` file to see who added
the conflicting change.

### Compare changes

In the git-novice lesson we learnt how to diff between commits
on the same branch.
You can also look at diffs between branches even if they are on
a different fork using GitHub.

To see a difference for a repository add `/compare`
to the end of the repository url.

1. Navigate to: [`https://github.com/MetOffice/git-training-demo/compare/`](https://github.com/MetOffice/git-training-demo/compare/),
and click on the **compare across forks** link.
2. Click on the **head repository** dropdown and find your fork.
3. Click on the **compare** dropdown and select your feature branch.

A diff should appear comparing your fork's feature branch with
the upstream repositories `main` branch.

## Resolving Conflicts

Expand Down

0 comments on commit f3af3ed

Please sign in to comment.