Re: Mergetool generating blank files (1.5.3)
- From
- Kelvie Wong <kelvie@ieee.org>
- Date
- Sep 27, 2007, 21:22 UTC
- Message-ID
- <94ccbe710709271422x5d1739c2g5da961c88a4336fe@mail.gmail.com>
- In-Reply-To
- <94ccbe710709271417h6349c807j6424c25175c26ea2@mail.gmail.com>
On 9/27/07, Kelvie Wong <kelvie@ieee.org> wrote:
Show 51 quoted lines
> On 9/27/07, Junio C Hamano <gitster@pobox.com> wrote:
> > Junio C Hamano <gitster@pobox.com> writes:
> >
> > > "Kelvie Wong" <kelvie@ieee.org> writes:
> > >
> > >> Egads, it's alive!
> > >>
> > >> I was in a subdirectory (most of my work is in that one subdirectory
> > >> anyways :p), but running it on the top level did indeed work as
> > >> expected.
> > >>
> > >> Thanks,
> > >
> > > Thanks for spotting a bug. It claims to be subdirectory safe at
> > > the top of the script but apparently it isn't.
> > >
> > > And I do not see a reason why it cannot be made subdirectory
> > > safe.
> >
> > It _could_ be just the matter of doing this, although I cannot
> > test it right now (at work and have no access to any of the
> > backends). Care to try it from a subdirectory and report
> > failure or success?
> >
> > ---
> >
> > git-mergetool.sh | 1 +
> > 1 files changed, 1 insertions(+), 0 deletions(-)
> >
> > diff --git a/git-mergetool.sh b/git-mergetool.sh
> > index a0e44f7..018db58 100755
> > --- a/git-mergetool.sh
> > +++ b/git-mergetool.sh
> > @@ -12,6 +12,7 @@ USAGE='[--tool=tool] [file to merge] ...'
> > SUBDIRECTORY_OK=Yes
> > . git-sh-setup
> > require_work_tree
> > +cd_to_toplevel
> >
> > # Returns true if the mode reflects a symlink
> > is_symlink () {
> >
>
> At least with emerge, this isn't so simple -- emacs tries to save it
> as ${absolute_PWD}/${PWD_relative_to_toplevel}/$filename
> (which of course doesn't exist yet).
>
> In meld it works fine, however; haven't tried the other ones.
> --
> Kelvie
>Hrm, on closer inspection, the old version of the mergetool script did this too.
It looks like the bug I mentioned does get fixed by that, and this is a bug in emacs (or the way it's called).
-- Kelvie