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

Re: Stashing untracked files

From
TTTom Tobin <korpios@korpios.com>
Date
Sep 30, 2007, 20:44 UTC
Message-ID
<bf0b20a90709301344j1ac8f538u616fb4ba3fc47efe@mail.gmail.com>
In-Reply-To
<46FE9924.7080006@theory.org>
On 9/29/07, Neil Macneale <mac4-git@theory.org> wrote:
Show 5 quoted lines
> When using "git stash," in some cases I'd like to stash away files that
> are currently untracked. It seems to me like there should be a way to
> stash everything in a working directory so that the end result is a
> pristine tree. Then applying the stash will reinstate those file as
> untracked.

Since this is an itch of my own, I have a local copy of git-stash that does this (stashes away the untracked -- but not ignored -- files, and restores them as untracked upon "stash apply"); unfortunately, I'm pretty new to git, so I'm certain my code is *quite* unoptimized and ugly. As soon as I feel comfortable with it (which should include making the new behavior optional), I'll drop a line here with some code. :-)

Previous: Johannes SchindelinNext: Johannes Schindelin
Message 12 of 13 in “Stashing untracked files”
  1. Neil MacnealeSep 29, 2007
  2. Johannes SchindelinSep 29, 2007
  3. Benoit SIGOURESep 29, 2007
  4. Neil MacnealeSep 29, 2007
  5. Johannes SchindelinSep 29, 2007
  6. Neil MacnealeSep 30, 2007
  7. Steffen ProhaskaSep 30, 2007
  8. Wincent ColaiutaSep 30, 2007
  9. Johannes SchindelinSep 29, 2007
  10. Tom PrinceSep 29, 2007
  11. Johannes SchindelinSep 29, 2007
  12. Tom TobinSep 30, 2007
  13. Johannes SchindelinSep 30, 2007

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.