emacs-devel
[Top][All Lists]
Advanced

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

Re: VC mode and git


From: Lele Gaifax
Subject: Re: VC mode and git
Date: Sat, 04 Apr 2015 23:41:32 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

"Stephen J. Turnbull" <address@hidden> writes:

> Harald Hanche-Olsen writes:
>  > Short summary of such an 
>  > explanation: They are the result of an incomplete merge operation, and 
>  > all come from origin/master at the time of his pull. This may not be the 
>  > *correct* explanation, but it is a *possible* explanation.
>
> Yes, and I've posted three times mentioning those posts (by Eli as
> well as you) and explaining the I have tried to reproduce this in a
> toy repo and have been unable to.  It's no longer a possible
> explanation that he pulled and these were left over *as far as I can
> tell*.  I worry that it may matter in getting his repo fixed up
> properly.

AFAICT, the following simple script replicates a similar case, with the same
outcome:

    RD=/tmp/rd_$$

    mkdir -p $RD

    git init $RD/remote
    cd $RD/remote
    for f in a b c
    do
        echo $f > $f
        git add $f
    done
    git commit -m "Bootstrap"

    cd $RD
    git clone remote local

    cd local
    echo "local tweak" >> a
    git add a
    git commit -m "Local tweak"

    cd $RD/remote
    for f in a b c
    do
        echo $f >> $f
        git add $f
    done
    git commit -m "Second pass"

    cd $RD/local
    git pull
    git status --short

Running it, you end with the following state in the "local" repository:

    UU a
    M  b
    M  c

where you see that the "a" file is "dirty" and contains conflict markers:

    $ cat a
    a
    <<<<<<< HEAD
    local tweak
    =======
    a
    >>>>>>> d2f149d20ecc0e259331d82497e0388828d940ad

My 2 cents,
ciao, lele.
-- 
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
address@hidden  |                 -- Fortunato Depero, 1929.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]