Monday, November 08, 2010 at 12:04 AM.
system.verbs.builtins.radio.backup.debug.comparePosts
local (adroutline = @system.temp.errors); new (outlinetype, adroutline); edit (adroutline); on addinfo (s) { local (oldtarget = target.set (@system.temp.errors)); op.insert (s, up); target.set (oldtarget)}; local (adr1 = @weblogdata.posts, adr2 = @scratchpad.posts); if sizeof (adr1^) != sizeof (adr2^) { addinfo ("They aren't the same size."); for nomad in adr1 { if not defined (adr2^.[nameof (nomad^)]) { addinfo (nameof (nomad^))}}}; bundle { //loop through both arrays local (nomad1, nomad2); for nomad1 in adr1 { nomad2 = @adr2^.[nameof (nomad1^)]; if not defined (nomad2^) { addinfo (nameof (nomad2^))} else { <<if string (nomad1^.text) != string (nomad2^.text) <<addinfo (nameof (nomad1^)) if nomad1^.when != nomad2^.when { addinfo (nameof (nomad1^))}}}}
This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.