Announcement

Collapse
No announcement yet.

How to ignore line if left side match a word

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

  • How to ignore line if left side match a word

    I'm comparing two files and I would like to ignore all the lines that contains the substring Profiler.GetLabel on the left file.
    For example I would like to consider the following files as identical:

    file 1 (left side):
    Code:
    string label = Profiler.GetLabel("FWCOMMON0336", Context.Lang);
    Console.WriteLine(label);
    file 2 (right side):
    Code:
    string label = "Hello";
    Console.WriteLine(label);

    Is it possible?

    Thanks

  • #2
    Hello,

    Unfortunately, this type of unimportance is not definable in BC3 (without some additional information).

    You could define the left line as Unimportant, but the right side would still be counted as an Important Difference.
    http://www.scootersoftware.com/suppo..._unimportantv3

    Alternatively, you could also use the BC3 Pro feature Text Replacements, and define a replacement of
    .* = string label = Profiler.GetLabel("FWCOMMON0336", Context.Lang);
    or
    .*Profiler.GetLabel.* = string label = "Hello";
    or
    (.*)Profiler.GetLabel.* = $1"Hello";

    But Text Replacements does not support a mask definition on both sides, so at least one side would need to use an explicit string.
    Aaron P Scooter Software

    Comment

    Working...
    X