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

Re: Stash does not save rename information

From
CWChrissy Wainwright <chrissy@sixfeetup.com>
Date
Dec 16, 2019, 14:32 UTC
Message-ID
<EF4FE28C-1111-46C7-9EDE-24940E8A5727@sixfeetup.com>
In-Reply-To
<87fthmzewl.fsf@kyleam.com>
Thank you, using --index does work! Now the trick is to actually remember to use it in this case, since it doesn't seem the change can be restored if you forget to use it the first time you pop/apply.
Then the fix is to `git mv` the files back to the original name, and to the new name again.
Thanks
Chrissy Wainwright
 
-- 
Six Feet Up, Inc.
Python & Cloud Expert Consulting 
Direct Line: +1 (317) 861-5948 x(604)
Email: chrissy@sixfeetup.com
https://sixfeetup.com
 

On 12/14/19, 5:05 PM, "Kyle Meyer" <kyle@kyleam.com> wrote:

    Kyle Meyer <kyle@kyleam.com> writes:
    >
    >     $ git init
    >     $ touch foo && git add foo && git commit -mfoo
    
    Sorry, I forgot to paste in the `git rm foo` step here.
    
    >     $ git stash
    >     $ git stash apply
    >     Removing foo
    >     On branch master
    >     Changes not staged for commit:
    >     	    deleted:    foo
    >
    >     no changes added to commit
    
Previous: Kyle MeyerNext: Bryan Turner
Message 4 of 6 in “Stash does not save rename information”
  1. Chrissy WainwrightDec 14, 2019
  2. Kyle MeyerDec 14, 2019
  3. Kyle MeyerDec 14, 2019
  4. Chrissy WainwrightDec 16, 2019
  5. Bryan TurnerDec 16, 2019
  6. Jeff KingDec 16, 2019

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.