git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: git faq : draft and rfc

From
Jon Loeliger <jdl@jdl.com>
Date
Feb 16, 2006, 14:32 UTC
Message-ID
<E1F9kBR-0005D0-7F@jdl.com>
> I'll try to add questions from the archives of this ml, I'm also open
> to any suggestions.

This is sort of the "missing" paragraph from the "git-checkout" man page. It's there now, but in the "-m" option.

jdl
Q.  Why won't git let me change to a different branch
    using "git checkout <branch>" or "git checkout -b <branch>"?
    Instead it just says:
        fatal: Entry 'foo.c' not uptodate. Cannot merge.
A.  You have changes to files in your working directory that
    will be overwritten, removed or otherwise lost if the checkout
    and change to the new branch were to proceed.  To fix this
    you may either check your changes in, create a patch of your
    changes and revert your files, or use the "-m" flag like this:
        git checkout -m -b my-branch
Message 1 of 1 in “Re: git faq : draft and rfc”
  1. Jon LoeligerFeb 16, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.