Skip to content

Instantly share code, notes, and snippets.

@RichieRunner
RichieRunner / gist:b13d49f559bcd2d21e0bf3227b907bad
Last active May 2, 2020 08:07
rebase forked repo with master branch from upstream
  1. CD into your current forked repo
  2. Add the remote repo and call it upstream
git remote add upstream https://github.com/original-repo/goes-here.git
  1. Fetch all branches from remote upstream
git fetch upstream
  1. Rewrite your forked master with the upstream's master using git rebase
@RichieRunner
RichieRunner / squash-committed-commits.md
Last active May 2, 2020 07:30
squash commits that already have been commited 😔
git reset --soft HEAD~7
git add --all
git commit -m "single desscriptive message"
git push --force

~7 is how many commits to go back to