#. Make the commits that you will later squash.
- #. Make the first commit.
+ A. Make the first commit.
::
# modified: glossary.rst
#
- #. Make the second commit.
+ B. Make the second commit.
::
# Changes to be committed:
# modified: architecture.rst
- #. Make the third commit.
+ C. Make the third commit.
::
#. There are now three commits in the feature branch. We will now begin the
process of squashing them into a single commit.
- #. Run the command ``git rebase -i main``, which rebases the current branch
+ A. Run the command ``git rebase -i main``, which rebases the current branch
(the feature branch) against the ``main`` branch:
.. prompt:: bash
git rebase -i main
- #. A list of the commits that have been made to the feature branch now
+ B. A list of the commits that have been made to the feature branch now
appear, and looks like this:
::
#. Now we create a commit message that applies to all the commits that have
been squashed together:
- #. When you save and close the list of commits that you have designated for
+ A. When you save and close the list of commits that you have designated for
squashing, a list of all three commit messages appears, and it looks
like this:
# modified: doc/architecture.rst
# modified: doc/glossary.rst
- #. The commit messages have been revised into the simpler form presented here:
+ B. The commit messages have been revised into the simpler form presented here:
::