Skip to content

Commit

Permalink
fix: comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kristof-mattei committed Nov 23, 2022
1 parent 8a03499 commit 2d2fe04
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions update-from-upstream.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,24 @@
#!/bin/bash

# fetch so we can merge in without first
# having to checkout & pull the branches
git fetch origin
git fetch upstream

# delete existing branch
git branch -D update-from-upstream

# we create a new branch from the origin's main (=HEAD, because we fetched)
git branch update-from-upstream origin/main

# check out the branch
git checkout update-from-upstream

# merge in the changes from upstream
git merge upstream/main

# set the current branch's upstream to where we need it to be so we can
# push without being prompted
git branch --set-upstream-to=origin/update-from-upstream update-from-upstream

# git push origin update-from-upstream

0 comments on commit 2d2fe04

Please sign in to comment.