From: "René Scharfe" <firstname.lastname@example.org> To: Robert Muchacki <email@example.com>, firstname.lastname@example.org Subject: Re: git - more like a feature request for pro-lifers Date: Sun, 26 Jul 2020 19:40:59 +0200 [thread overview] Message-ID: <email@example.com> (raw) In-Reply-To: <B56E3052-2BD5-42D5-A854-2FAB528C3214@gmail.com> Am 21.07.20 um 10:28 schrieb Robert Muchacki: > Greetings! > > Attached is a feature request for the pro-lifers. Doesn’t seem to much work to do in the code. Commenting on attached files is hard, so here's your bug report inlined: > Thank you for filling out a Git bug report! > Please answer the following questions to help us understand your issue. > > What did you do before the bug happened? (Steps to reproduce your issue) > I tried to switch branches: > ``` > > git checkout other_branch > ``` When I do that I get: $ git init -q a; cd a; echo 1 >a; git add a; git commit -q -m1 $ git checkout other_branch error: pathspec 'other_branch' did not match any file(s) known to git If I create that branch, then I get: $ git branch other_branch $ git checkout other_branch Switched to branch 'other_branch' If I create yet another branch, commit a modification, then modify the file and try to switch to that branch, I get: $ git branch branch; echo 2 >a; git add a; git commit -q -m2 $ echo 3 >a $ git checkout branch error: Your local changes to the following files would be overwritten by checkout: a Please commit your changes or stash them before you switch branches. Aborting > What did you expect to happen? (Expected behavior) > A friendly information, not confusing, not anti-life, that will tell me why the process stopped. > > > What happened instead? (Actual behavior) > I got a non-pro-life informatiom, that noticed that it was ABORTING. So you got the same kind of message that I got on my third attempt above, right? That means some files were modified and switching to the other branch would have destroyed those changes. Git detected that and refused, to protect your code changes. > What's different between what you expected and what actually happened? > It should have been STOPPED or ENDED. ABORTING and TERMINATING is unrespectful for the unborn code. Overwriting unexpectedly changed files would be irresponsible, so we need to keep this feature. Users can discard changes in more targeted ways, if that is really what they want to do. I don't see how any of git checkout's messages is unfriendly, but you somehow seem to dislike the "Aborting" part at the end of the third one. https://en.wiktionary.org/wiki/abort#Verb lists nine meanings: 1. To miscarry; to bring forth (non-living) offspring prematurely. 2. To cause a premature termination of (a fetus); to end a pregnancy before term. 3. To end prematurely; to stop in the preliminary stages; to turn back. 4. To stop or fail at something in the preliminary stages. 5. To become checked in normal development, so as either to remain rudimentary or shrink away wholly; to cease organic growth before maturation; to become sterile. 6. To cause an organism to develop minimally; to cause rudimentary development to happen; to prevent maturation. 7. To abandon a mission at any point after the beginning of the mission and prior to its completion. 8. To terminate a mission involving a missile or rocket; to destroy a missile or rocket prematurely. 9. To terminate a process prior to completion. The third, fourth and ninth are appropriate here: A checkout was started, but had to be called off to protect uncommitted changes. "Abending" would also fit and it has no other meanings. "Staying on current branch." would be more to the point. But actually I'm not sure we need that last line. It's shown to emphasize that the requested action was cancelled, but I can infer that from the rest of the comprehensive error message already, or even from the the fact that an error was reported at all. Would that work as well for new or less technical users? Dunno. > > Anything else you want to add: > > Please review the rest of the bug report below. > You can delete any lines you don't wish to share. > > > [System Info] > git version: > git version 2.27.0 > cpu: x86_64 > no commit associated with this build > sizeof-long: 8 > sizeof-size_t: 8 > uname: Darwin 19.6.0 Darwin Kernel Version 19.6.0: Sun Jul 5 00:43:10 PDT 2020; root:xnu-6153.141.1~9/RELEASE_X86_64 x86_64 > compiler info: clang: 11.0.3 (clang-1126.96.36.199) > libc info: no libc information available > > > [Enabled Hooks]
prev parent reply other threads:[~2020-07-26 17:41 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-07-21 8:28 Robert Muchacki 2020-07-26 17:40 ` René Scharfe [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style List information: http://vger.kernel.org/majordomo-info.html * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --subject='Re: git - more like a feature request for pro-lifers' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Code repositories for project(s) associated with this inbox: https://80x24.org/mirrors/git.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).