Re: [PATCH 08/19] checkout: split part of it to new command switch
- From
Duy Nguyen <pclouds@gmail.com>
- Date
- Jan 31, 2019, 07:43 UTC
- Message-ID
- <CACsJy8C2fx-+NxS+ahmmHDgLrwtyiCV6WEEfpmYwfcPM3kYVvA@mail.gmail.com>
- In-Reply-To
- <CAPig+cS4Dmgh+hCMXp8ND5DMy6QFVCJOgvDwpcbwZ0HV4MscpA@mail.gmail.com>
On Thu, Jan 31, 2019 at 1:25 PM Eric Sunshine <sunshine@sunshineco.com> wrote:
Show 8 quoted lines
> I find, however, that the top-level git-switch "DESCRIPTION" section, > which talks about "switching branches" doesn't actually ever explain > what it means to "switch" to a branch. Even adding a simple sentence > stating that "switching to a branch means that a newly-created commit > will be a direct child of the current head of the branch, and that the > branch will be updated to point at the new commit" would help cement > the meaning of branch switching in the reader's mind (rather than > assuming the reader understands that implicitly).
Thanks. How about this? I skipped the "update branch to point to the new commit" because that sounds like something you should learn from git-commit and hopefully the word "commit" would be enough to recall that knowledge (or direct the user to git-commit.txt). I notice git-commit.txt does not say anything about branch update business though. Maybe some more updates there...
DESCRIPTION ----------- Switch to a specified branch. The working three and the index are also updated to match the branch. All new commits will be added to the tip of this branch.
Optionally a new branch could be created with either `-c` or `-C`, or detach the working tree from any branch with `--detach`, along with switching.
-- Duy