Announcement

Collapse
No announcement yet.

comparing source when blocks are moved

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • comparing source when blocks are moved

    Is there an easy way to compare source files where there are not only big insertions/deletions, but also block moves? And compare the blocks, even though they moved?

    Sepcifically, I'm looking at c-files, and sometimes it is desirable to reorder procedures in a given file. I would like to know what the diffs in procX() in old\file.c are versus procX in new\file.c.

    I've played with the alignment settings very briefly, and they don't help with this particular job.

    I can think of some extreme solutions, such as an external conversion that munges old\file.c to old\tfile.c with the order of procedures matched to new\file.c, or treating the files as "archives" and comparing "subfiles" within the "archvies". But am I overlooking something that is already available?

    Tnx
    /dps


  • #2
    Re: comparing source when blocks are moved

    Beyond Compare doesn't detect moved sections of text. The only option is to use an external conversion utility to sort the sections as you described.

    Detecting moved sections of text is on our wish list for a future release of Beyond Compare.
    Chris K Scooter Software

    Comment


    • #3
      Re: comparing source when blocks are moved

      I'll be watching for it!

      10x

      /dps

      Comment


      • #4
        Re: comparing source when blocks are moved

        Meanwhile, the current "crisis" was dealt with by using "align manually" from the context menu; this works for small numbers of moved blocks.

        /dps

        Comment


        • #5
          Looking for a status update... has this been implemented?

          Comment


          • #6
            It has not yet been. We have a kb article going into greater detail on external conversions here:
            http://www.scootersoftware.com/suppo...rnalconversion
            Aaron P Scooter Software

            Comment


            • #7
              Please implement this
              Notepad++ compare plugin had this and I turned to BC as I thought - well surely with BC I might as well hide the moved around sections and concentrate on real differences

              Well - Beyond Compare is Before Compare vis a vis moving

              NB : I am comparing files post and ante *sorting* (to verify I sort them well) - so I don't think sorting is an option

              NB2 : the N++ compare plugin *fails* to detect all the moves - it won't be easy (I should only see moves in the files I am comparing)

              Comment


              • #8
                Detecting moved columns is still on our wishlist, but sorting is the only method we currently support. You can enable "Disable editing" as part of the conversion process, which would prevent the files from re-saving in the sorted order. This way, the sort is only for comparison purposes to verify if all of the data is present.
                Aaron P Scooter Software

                Comment

                Working...
                X