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

Re: [PATCH] git stash: Give friendlier errors when there is nothing to apply

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 14, 2009, 19:52 UTC
Message-ID
<7v3a7ujhqb.fsf@alter.siamese.dyndns.org>
In-Reply-To
<4a81787d.0e0f660a.5238.4c8b@mx.google.com>
Ori Avtalion <ori@avtalion.name> writes:
Show 16 quoted lines
> The change makes sure a stash (given or default) exists before
> checking if the working tree is dirty.
>
> If the default stash is requested, the old message was scary and
> included a 'fatal' error from rev-parse:
>      fatal: Needed a single revision
>      : no valid stashed state found
>
> It is replaced with a friendlier 'Nothing to apply' error, similar to
> 'git stash branch'.
>
> If a specific stash is specified, the 'Needed a single revision' errors
> from rev-parse are suppressed.
>
> Signed-off-by: Ori Avtalion <ori@avtalion.name>
> Acked-by: Thomas Rast <trast@student.ethz.ch>

I do not see anything that might break existing usage of the command. Comments?

A tangent; we might want an analogue to "shortlog -s -n" but based on "blame".

Previous: Thomas RastNext: Nanako Shiraishi
Message 5 of 7 in “git stash: Give friendlier error when there is nothing to apply”
  1. git stash: Give friendlier error when there is nothing to applyOri Avtalion, Aug 11, 2009
  2. Thomas RastAug 11, 2009
  3. git stash: Give friendlier errors when there is nothing to applyOri Avtalion, Aug 11, 2009
  4. Thomas RastAug 13, 2009
  5. Junio C HamanoAug 14, 2009
  6. Nanako ShiraishiAug 14, 2009
  7. Junio C HamanoAug 15, 2009

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.