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

Re: [PATCH] stash: end commit log with a newline

From
しらいしななこ <nanako3@bluebottle.com>
Date
Jul 4, 2007, 23:18 UTC
Message-ID
<200707042324.l64NOp8J019289@mi0.bluebottle.com>
In-Reply-To
<20070704074444.GA5687@informatik.uni-freiburg.de>
Quoting Uwe Kleine-König  <ukleinek@informatik.uni-freiburg.de>:
Show 23 quoted lines
> Junio C Hamano wrote:
>> I noticed another thing.  The entries shown in "git stash list"
>> look like this:
>> 
>> stash@{0}: js/stash: e1d32c1... Teach git-stash to "apply --index"
>> stash@{1}: master: 5be6007... Rewrite "git-frotz" to "git frotz"
>> stash@{2}: master: 36e5e70... Start deprecating "git-command" in favor of "git command"
>> stash@{3}: master: 3b0d999... Merge branch 'jo/init'
>> 
>> But each of the stash is _not_ about these commits, but is about
>> some change that happens to be on top of them.
>> 
>> So risking to make it a tad longer, how about doing this on top?
>> 
>> -	git update-ref -m "$msg" $ref_stash $w_commit ||
>> +	git update-ref -m "WIP on $msg" $ref_stash $w_commit ||
>
> I like that.  I already wondered about that, too.  But not as much as
> thinking about an alternative.
>
> So:
>
> Acked-by: Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de>

I am sorry to join the discussion late, but I think it is much better to let the user give a short reminder message from the command line. For example,

  $ git stash add customized message to stash

When I say "git stash list", I want to see which branch I was on when I was in the middle of doing something, and what that something was. It is not interesting which commit on that branch I started that change from. After creating a stash without a message, and then another stash with a message, I want to see:

  $ git stash list
  stash@{0}: On master: add customized message to stash
  stash@{1}: WIP on master: 36e5e70... Start deprecating "git-command" in favor of "git command"
-- 
Nanako Shiraishi
http://ivory.ap.teacup.com/nanako3/

----------------------------------------------------------------------
Free pop3 email with a spam filter.
http://www.bluebottle.com/tag/5
Previous: Uwe Kleine-König
Message 8 of 8 in “stash: end commit log with a newline”
  1. stash: end commit log with a newlineUwe Kleine-König, Jul 3, 2007
  2. Johannes SchindelinJul 3, 2007
  3. Uwe Kleine-KönigJul 3, 2007
  4. Jeff KingJul 3, 2007
  5. しらいしななこJul 4, 2007
  6. Junio C HamanoJul 4, 2007
  7. Uwe Kleine-KönigJul 4, 2007
  8. しらいしななこJul 4, 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.