Perforce extension to use a custom content comparison tool for specific file extensions

I have various user binaries stored in perforce, and for many file types I created my own comparison tool to show the creators of the content the difference with the actual changes in the file.

eg. If the file contains a pair of simple keys as a compressed binary block, the diff tool loads each version into a format in memory and generates a list of additions, deletions, and changes to the file, presented in a good clean presentation of the report.

Like the built-in image comparison tool in P4V, I would like to use my own tool to identify specific file extensions in my repository and allow users to use the existing P4V interface to select revisions for the difference between study history.

So, I know that you can write add-ons for P4V, but I canโ€™t find documentation for it, and I would like to know if this extension function is available in P4V and how to use it?

+4
source share
2 answers

When researching meta-diff from another answer, I found a solution built into P4V. It turns out that in the P4V dialog box that you use to specify your diff tool, there is an additional set of options for specifying another tool for different file extensions.

So, I donโ€™t need to write a plugin or extend p4v at all, I just need to set these properties correctly.

+7
source

I do not use Perforce, but you must do this using meta-diff , which allows you to configure different diff utilities for different types of files.

0
source

Source: https://habr.com/ru/post/1305039/


All Articles