WEEK 7 · LESSON 10 · TOPIC 5 OF 8 · Practical Application

Practical Application

Lesson progress

0% Complete

SECTION 1 OF 1

In this topic · 1 sections
  1. Overview

Overview

A rebase workflow is:

  1. Create a feature branch from main.
git checkout main
git branch feature
git checkout feature
  1. Make and commit feature work.
git add .
git commit -m "Add feature functionality"
  1. Allow main to receive newer commits through other work.
  2. Return to feature.

git checkout feature

  1. Rebase feature onto the updated main branch.

git rebase main

  1. Inspect the result.

git log --oneline

The log should show the newer main commits followed by the replayed feature commits.