Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package require twapi
- proc diff {file1 file2} {
- set f1 [open $file1 "rb"]
- set f2 [open $file2 "rb"]
- try {
- while 1 {
- if {[read $f1 4096] ne [read $f2 4096]} {
- return 0
- } elseif {[eof $f1]} {
- # The same if we got to EOF at the same time
- return [eof $f2]
- } elseif {[eof $f2]} {
- return 0
- }
- }
- } finally {
- close $f1
- close $f2
- }
- }
- CreateObject("Wscript.Shell").Run "diff.tcl",0,True
Add Comment
Please, Sign In to add comment