# [BUG] git-gui: "Stage Hunk For Commit" doesn't work at all anymore

3 messages from 2007-08-23 to 2007-08-24. Participants: Brian Downing, Shawn O. Pearce.
Thread: https://gitlist.dev/t/9626

## Brian Downing, 2007-08-23 20:30

Subject: [BUG] git-gui: "Stage Hunk For Commit" doesn't work at all anymore
Message-ID: <20070823203024.GF21692@lavos.net>
URL: https://gitlist.dev/e/20070823203024.GF21692%40lavos.net

```
This commit:

commit a13ee29b975d3a9a012983309e842d942b2bbd44
Author: Shawn O. Pearce <spearce@spearce.org>
Date:   Thu Aug 2 22:55:22 2007 -0400

    git-gui: Avoid Tcl error in popup menu on diff viewer

    If there is no path currently shown in the diff viewer then we
    were getting Tcl errors anytime the user right-clicked on the
    diff viewer to bring up its popup menu.  The bug here is caused
    by trying to get the file_state for the empty string; this path
    is never seen so we never have file_state for it.  In such cases
    we now disable the Stage Hunk For Commit option.

    Signed-off-by: Shawn O. Pearce <spearce@spearce.org>

seems to have broken the "Stage Hunk For Commit" option entirely for me
-- it is now disabled whether or not there is a patch in the viewer.

-bcd

```

## Brian Downing, 2007-08-23 20:38

Subject: Re: [BUG] git-gui: "Stage Hunk For Commit" doesn't work at all anymore
Message-ID: <20070823203818.GG21692@lavos.net>
URL: https://gitlist.dev/e/20070823203818.GG21692%40lavos.net
In-Reply-To: <20070823203024.GF21692@lavos.net>

```
On Thu, Aug 23, 2007 at 03:30:24PM -0500, Brian Downing wrote:
> This commit:
> 
> commit a13ee29b975d3a9a012983309e842d942b2bbd44
> 
> seems to have broken the "Stage Hunk For Commit" option entirely for me
> -- it is now disabled whether or not there is a patch in the viewer.

Sorry, I just saw the following commit in the git-gui tree:

ce015c213fbef39140b6192db28110bc666dc6c8 
git-gui: Paper bag fix "Stage Hunk For Commit" in diff context menu

So it appears this issue is known.  Sorry about the noise.

(Though this will be merged before 1.5.3, right?)

-bcd

```

## Shawn O. Pearce, 2007-08-24 03:08

Subject: Re: [BUG] git-gui: "Stage Hunk For Commit" doesn't work at all anymore
Message-ID: <20070824030808.GT27913@spearce.org>
URL: https://gitlist.dev/e/20070824030808.GT27913%40spearce.org
In-Reply-To: <20070823203818.GG21692@lavos.net>

```
Brian Downing <bdowning@lavos.net> wrote:
> On Thu, Aug 23, 2007 at 03:30:24PM -0500, Brian Downing wrote:
> > This commit:
> > 
> > commit a13ee29b975d3a9a012983309e842d942b2bbd44
> > 
> > seems to have broken the "Stage Hunk For Commit" option entirely for me
> > -- it is now disabled whether or not there is a patch in the viewer.

Yea, that commit was a dud.  I noticed it myself a few days ago
and fixed the dang thing.  I don't know what I was thinking when
I made that commit...
 
> Sorry, I just saw the following commit in the git-gui tree:
> 
> ce015c213fbef39140b6192db28110bc666dc6c8 
> git-gui: Paper bag fix "Stage Hunk For Commit" in diff context menu
> 
> So it appears this issue is known.  Sorry about the noise.

No problem.  Better that someone raises an issue than just pretend
like its not there...
 
> (Though this will be merged before 1.5.3, right?)

Yes.  It will be in git-gui 0.8.2, which Junio has agreed to merge
into 1.5.3 before it goes final.  I'll likely tag git-gui 0.8.2
tomorrow, then ask him to pull when he has the chance.

-- 
Shawn.

```
