I'm programming intelligent diff in php. Which will be used for comparing two files whose content are configuration of router in two time period. As an output I need make colored highlighting of difference or if its on different place (line).
For example input one:
185.255.0.0/26 is subnetted, 1 subnets
172.16.0.0/16 is directly connected, Vlan 50
input two:
185.255.0.0/26 is subnetted, 15 subnets
172.16.0.0/16 is directly connected, Vlan 5
Now I can stupidly recognise if the lines are same or simmilar by computing matrix of levensthein distance. Can you advise me any other algorithm which could help mi with highligting differences? I probably need similar algorithms like are used in subversion or compare in total commander. Could you advise me where could I look?