Two Dimensional Directory Diff

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • DaveKellogg
    New User
    • May 2004
    • 1

    Two Dimensional Directory Diff

    I'd like to see this enhancement to BC:

    A directory difference view, where for each file in the vertical directory list, there is a horizontal bar that is similar to the thumb-nail view (show on the left when viewing a single file diff). Given this, I could rapidly get an overall feel for the extent and location of differences between all of the files in two directories.

    It would be nice to be able to drag the thumb nail index left-and-right for the current file, and see the corresponding side-by-side differences in a window at the bottom of the screen. I'd like to be able to move easily between different thumb-nails for different files by simple clicking in a different thumb-nail.

    Different files will be different lengths. ie, one might be 200 lines, and another 1500 lines. Thus I'd like to have two different ways of comparing thumb-nails between files: One could be normalized to the length of that file. ie, the width of changes in the thumb-nail could be thought of as a percentage of the corresponding file.

    The second mode would be where the horizontal space in a thumb-nail is the same between all files. This would be more valuable to me, since it is more of an absolute comparision across all files in the directory. Because different files can be significantly different in size, there should be some kind of horizontal zoom in/out magnification for the entire set of thumb-nails as a set, and also a horizontal scroll bar.

    Given this capability, I could diff two directories and see (all in one view) what files differ, the extent of the differences in each file, and the type of those differences (additions, new lines, deletions, etc).

    Of course, many of BC's other features could be invoked on this view, such as filtering the set of files, and ignoring unimportant differences.

    As for the vertical list of files, I envision an icon on each file that indicates which is newer, orphaned, etc.

    It would also be nice if there were columns that could be enabled for each file in the list, showing file size (in bytes and/or lines) for each the left and/or right directories, the date for the left and/or right file, and the magnitude of the difference (in # of sections, lines, and/or characters). I'd also like a summary line showing the sum for each of these items for all of the currently shown files (subject to current file filtering and enabling/disabling of unimportant changes).

    For the frosting on the cake, I'd like to be able to print out this view (in color), where the print-out would be extended vertically if the list of files is too long to be shown completely on the screen.

    I'm a software engineer, and I work with a number of directories of source code. BC is excellent for showing the differences within a single file, and for showing what and how many files differ between two directories. Having these capabilities described earlier would be an excellent extension to BC, and would help me greatly in rapidly comprehending the extent of differences between two source code directories, each containing several hundred files of code.

    Please contact me if you'd like more input about this concept.

    PS:
    Most larger software development projects use a Version Control system (VCS). Suppose that I write a little script magic that would extract each revision of a particular source file from VCS into a commensurately named file (say where the file name is the revision number or the time and date of the revision). Suppose that I copy the directory to a second directory, and write a little more script magic, such that in the second directory each file is renamed with the next filename in the sorted list. eg, FileRev1.c is renamed as FileRev2.c, FileRev2.c is renamed as FileRev3.c, etc.

    Now, given the 2-dimentional thumb-nail view capability described above, then I can run a diff between the two directories and be rewarded with a BD screen showing the graphical evolution of the original source file over a range of revisions.

    This view of a VCS file is quite useful. The neat thing is that BC could provide this VCS presentation capability without any direct dependencies on a particular VCS system. Since the user's script issues the loop of extraction commands, BC does not care about the syntax of any particular VCS.

    Now suppose that an option was added to BC whereby it could compare between sequentially named files in a single directory. This may be regarded as somewhat of a limited-use feature, but I can see other uses for it. eg, a directory of log files of system build attempts, where there is one log file named for each build. Anyway, having this feature would remove the need for the second directory with each of the renamed files.

    Yet another ue of this 2-D thumb-nail capability would be to use a little more script magic to extract from VCS all the files for a paticular version of the system, and concatenate them into a single file that is named to correspond with that version (eg, perhaps wtih the date and time in YY-MM-DD-HH-MM format). Make the constraint that the constituent files are always concatenated in sorted filename order. This we end up with all of the files needed for a release of the system in one monster file. Now have the script magic run a loop over the concatenation, and create a concatenated file for each release of the system.

    Now when I do a 2-D thumb-nail difference, what I get is a picture of all of the changes in all of the source files, over a number of releases. This is the sort of picture that helps graphically quantify (particularly for non-software people eg, managers) the extent of changes over several releases.

    It might be that a tiled print-out would be needed, in order to show some resonable resolution in the thumb-nails. I have also assumed that the thumb-nail won't "lose sight of" relatively small changes in a large file.

    So here are a couple of additional uses for a D-2 directory diff. It would help me a lot if Scooter Software would make these enhancements.
  • Chris
    Team Scooter
    • Oct 2007
    • 5538

    #2
    Re: Two Dimensional Directory Diff

    Hi Dave,

    Thank you for the great suggestion.
    I will add it to the wishlist.
    Chris K Scooter Software

    Comment

    Working...