External Diff

This forum allows you to share scripts with other Zeus users. Please do not post bug reports, feature requests or questions to this forum, but rather use it exclusively for posting scripts or for the discussion of scripts that have been posted.
Post Reply
amif2000
Posts: 14
Joined: Sun Dec 10, 2006 3:14 pm

External Diff

Post by amif2000 »

This simple script will take the current buffer and the one to its right (in the tab order) and run an external diff between them.

To use a different diff utility, change the 'local cmd = ...' line.

Code: Select all

function key_macro()
 screen_update_disable()
 local fname1 = get_file_name()
 WindowNext()
 local fname2 = get_file_name()
 WindowPrevious()
 screen_update()

 local cmd = 'winmerge.exe /e "' .. fname1 .. '" "' .. fname2 .. '"'
 --message_box(1,cmd)
 system(cmd)

end
key_macro()
Amit
Post Reply