1.
Answer the following questions using Figure 4.1.1
(a)
Which commits (give the colors) were merged into the upstream
main after the contributor created their local feature branch?
-
Red
-
Yellow
-
Green
-
Blue
-
Pink
-
Lime Green
Hint.
Look at which commits are in the upstream
main branch that are not part of the local repository’s main branch.
(b)
Which of the commits did the managers merge from the contributor’s pull request?
-
Red
-
Red was in
mainprior to the contributor creating the feature branch. -
Yellow
-
Yellow was in
mainprior to the contributor creating the feature branch. -
Green
-
Green was in
mainprior to the contributor creating the feature branch. -
Blue
-
Correct!
-
Pink
-
Pink was part of another contributor’s pull request.
-
Lime Green
-
Lime green was part of another contributor’s pull request.
Hint.
Look at which commits are in the local repository’s feature branch.
(c)
Which of the following statements explains how the pink commit might have gotten into the upstream
main branch?
-
The contributor made the pink commit to their feature branch.
-
The contributor’s feature branch did not contain the pink commit.
-
A maintainer merged the contributor’s pull request.
-
The contributor’s pull request contained the blue commit, not the pink commit.
-
A maintainer merged a pull request from another contributor which contained the pink commit.
-
Correct!
-
The pink commit is not part of the upstream
main. -
The pink commit is part of the upstream
main. It was merged after the pull request that contained the blue commit.
Hint.
Look at which commits are in the local repository’s feature branch. This shows the changes made by this contributor. Other changes were made by other contributors and accepted by the maintainer as a pull request.

