Re: Changed diff3 view from 2.36 → 2.67 for vimdiff

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dear Martin, dear Fernando,

first of all: Thank you both very much for your super fast and elaborate answers. It's amazing to get responses from the developers themselves! I read the blog post about the new vimdiff layout with delight. I like the new feature very much, especially the decision and implementation of the generic mechanism which is indeed better than the introduction of new vimdiff4, … layouts. I think I'll stick to the “advanced” four tab option for my future merge conflicts, like you suggested in your blog, too.

Regarding the problem, yes, you both were right, I have had a “second rogue” vimrc in my home directory. It has been – as most often – a “layer eight” problem (myself). I have had a ~/.vim directory with a ~/.vim/vimrc file inside. Since I had expected Vim to need an ~/.vimrc file, I had created a symbolic link ~/.vimrc -> ~/.vim/vimrc. “Nuking“ my vimrc had meant for me to delete this symbolic link (~/.vimrc), but as I learned today, the ~/.vim/vimrc file is perfectly fine. You always learn new things! So to really nuke the vimrc, I had to move the .vim directory as well and then git behaved like expected, just like you suggested.

I investigated further and – oh wonder! – I found those two lines in my vimrc:

set splitbelow
set splitright

Uncommenting them brought the good old back behavior back, too. So the problem is solved, great!!!

By the way, the buggy layout looked exactly like Matthew Klein reported in Martins link [1]. The difference is, obviously, the difference in tools (his --tool=nvimdiff versus mine --tool=vimdiff).

    ------------------------------------------
    |                                        |
    |                LOCAL                   |
    |                                        |
    ------------------------------------------
    |             |           |              |
    |   LOCAL     |   LOCAL   |   MERGED     |
    |             |           |              |
    ------------------------------------------

I also managed to compile the newest master branch of git (the Arch User Repository git-git package should be fixed, it's broken at the moment, but I managed to bypass all obstacles) and, as you hinted, this version (git version 2.37.1.223.g6a475b71f8) is not sensitive to the "splitbelow / splitright" options!

After successfully compiling Git, I'm almost ashamed to ask, but I was NOT able to run the vim command you suggested, Fernando:

vim -c "echo | split | vertical split | 1b | wincmd l | vertical split | 2b | wincmd l | 3b | wincmd j | 4b | tabdo windo diffthis" -c "tabfirst" local.txt base.txt remote.txt merged.txt

because there are no such files?! What do I have to do before executing this command? I read the man page and tried it with "git config mergetool.keepTemporaries true" and "git config mergetool.keepBackup true", but still no such files appear. I am sure I am missing something completely obvious. Even my google-foo failed… Since I solved my problem on many levels (thanks to your great help), executing those vim commands is not important anymore, I just would like to understand…

Thank you very much again,

with best regards,
Claudio

[1] https://lore.kernel.org/git/CACRpdvnuAYY0U1_3uD8zKgtq05+bgwjzXpZKomro6gqYDNrjGg@xxxxxxxxxxxxxx/




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux