edgi-govdata-archiving / go-calc-diff

🔍 Go diffing service for comparing changes to webpages
1 stars 0 forks source link
diff diffing web-monitoring

Differ

first, install go, then cd to the folder, build & run. default port is 8080.

$ cd differ
$ go build
$ ./differ

It's only got one route: /, hit it with a & b query params, where a & b are urls to diff, eg:

http://localhost:8000/diff?a=http://www.apple.com&b=http://www.apple.com/a

an extra param format sets the output format, which takes one of html, htmlraw, text or json, default is html.

diffing settings can also be controlled by passing in additional query params, setting things like matchThreshold & matchDistance, in lieu of proper documentation, please see the NewDifferFromRequest func in differ.go.