[Note: In this 2nd try, I've indented everything by a tab
to help avoid reinterpretation/reformatting of some of the
text.]

        I'm going to comment about the notations mean, not
        about that the specific type of file is not one
        you would be likely to have other than sn
        official-content-only status for. My notes are yet
        another alternative wording since you are
        uncomfortable with things in this area, just in
        case it helps.

        bob prohaska <fbsd_at_www.zefox.net> wrote on
        Date: Thu, 15 Jun 2023 17:26:48 UTC :
        
>       Here's an example of the puzzles faced when using etcupdate
>       that have so far proved baffling:
> 
>       On running etcupdate resolve, the system reports
> 
>       Resolving conflict in '/etc/mtree/BSD.tests.dist':
>       Select: (p) postpone, (df) diff-full, (e) edit,
>               (h) help for more options: df
>       --- /etc/mtree/BSD.tests.dist   2023-05-29 08:29:48.174762000 -0700
>       +++ /var/db/etcupdate/conflicts/etc/mtree/BSD.tests.dist        
> 2023-06-13 22:55:04.284491000 -0700
>       @@ -442,6 +442,16 @@
>                ..
>                ifconfig
>                ..
>       +<<<<<<< yours
>       +||||||| original
>       +        md5
>       +        ..
>       +=======
>       +        ipfw
>       +        ..
>       +        md5
>       +        ..
>       +>>>>>>> new
>                mdconfig
>                ..
>                nvmecontrol
>       Select: (p) postpone, (df) diff-full, (e) edit,
>               (h) help for more options: e
> 
>       Selecting option e for edit brings up what appears to be a
>       vi window, using search I can find the line with mdconfig:
> 

        For:

>       <<<<<<< yours
>       ||||||| original
>               md5
>               ..
>       =======
>               ipfw
>               ..
>               md5
>               ..
>       >>>>>>> new

        The:

        ||||||| original
        md5
        ..
        =======

        indicates the prior official version's material
        (the middle two lines of the 4 in this case).

        The:

        <<<<<<< yours
        ||||||| original

        has an empty middle indicating what was found
        in the file on your machine. The empty middle
        indicates that the "md5" and ".." lines had
        been deleted somehow, relative to want was
        official.

        The:

        =======
        ipfw
        ..
        md5
        ..
        >>>>>>> new

        indicates the new official version's content
        for what originally had just the "md" and ".."
        lines.

        You might pick one of the 3 blocks to keep and delete
        the rest of the lines (including <<<<..., ====...,
        and >>>>...) or you might replace everything
        from <<<<... to >>>>... (inclusive) with the text that
        you know you want in that area.

        (In this case you likely want the new text that also
        has "ipfw" material included.)

        It is possible for a file to have multiple of these
        kinds of "yours...original...new" blocks in the
        file.

>               mdconfig
>               ..
>               nvmecontrol
>               ..
>               pfctl
>                   files
>                   ..
>               ..
>               ping
>               ..
> 
>       The puzzle at this point is what to do. It's looks like the
>       points of interest are the lines marked "yours" and "new",
>       but I'll admit to bafflement which to modify and whether
>       the modifications needed include the <<<< and >>>>> characters.
> 
>       If there's a relevant man section please point it out.

        "man git-merge" has the following text describing such notations:
        (Again I'm not sure how nice the display will end up being.)

               An alternative style can be used by setting the 
"merge.conflictStyle"
               configuration variable to either "diff3" or "zdiff3". In "diff3" 
style,
               the above conflict may look like this:

                   Here are lines that are either unchanged from the common
                   ancestor, or cleanly resolved because only one side changed,
                   <<<<<<< yours:sample.txt
                   or cleanly resolved because both sides changed the same way.
                   Conflict resolution is hard;
                   let's go shopping.
                   ||||||| base:sample.txt
                   or cleanly resolved because both sides changed identically.
                   Conflict resolution is hard.
                   =======
                   or cleanly resolved because both sides changed the same way.
                   Git makes conflict resolution easy.
                   >>>>>>> theirs:sample.txt
                   And here is another line that is cleanly resolved or 
unmodified.


               while in "zdiff3" style, it may look like this:

                   Here are lines that are either unchanged from the common
                   ancestor, or cleanly resolved because only one side changed,
                   or cleanly resolved because both sides changed the same way.
                   <<<<<<< yours:sample.txt
                   Conflict resolution is hard;
                   let's go shopping.
                   ||||||| base:sample.txt
                   or cleanly resolved because both sides changed identically.
                   Conflict resolution is hard.
                   =======
                   Git makes conflict resolution easy.
                   >>>>>>> theirs:sample.txt
                   And here is another line that is cleanly resolved or 
unmodified.


               In addition to the <<<<<<<, =======, and >>>>>>> markers, it uses
               another ||||||| marker that is followed by the original text. 
You can
               tell that the original just stated a fact, and your side simply 
gave in
               to that statement and gave up, while the other side tried to 
have a
               more positive attitude. You can sometimes come up with a better
               resolution by viewing the original.

        I found that text via use of:

        # man -K ">>>>>"

        and the looking more at some of the files listed.

===
Mark Millard
marklmi at yahoo.com


Reply via email to