Project

urldiff

0.0
Repository is archived
No release in over 3 years
Low commit activity in last 3 years
Computes and displays the visual differences between two URLs
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies
 Project Readme

URLdiff

Computes and displays the visual differences between two URLs

urldiff takes two URLs, renders them as images and compares them pixel by pixel outputs the visual difference in percentage between the two URLs and and generates a colour image of the differences.

Gem Version

Install:

gem install urldiff

Requires:

  • Gems
gem install oily_png imgkit wkhtmltoimg_binary

Tested on Ruby 2.1.0

Usage:

urldiff.rb -i sitelist.csv -o output.csv

Options:

-i FILE read from CSV
-o FILE output (append) results to CSV
-f URL compare one site - First site
-s URL compare one site - Second site

Example:

# cat sites.csv
http://www.google.com.au,http://www.google.co.nz

# urldiff.rb -i sites.csv -o output.csv

Rendering http://www.google.com.au
Rendering http://www.google.co.nz
Calculating Diff...
pixels (total):     1024000
pixels changed:     6269
pixels changed (%): 0.61220703125%

Generating DIFF-www.google.com.au-www.google.co.nz.png

Appending output to output.csv

# cat output.csv
http://www.google.com,http://www.google.co.nz,0.61220703125%

# ls *.png
www.google.com.au.png
www.google.co.nz.png
DIFF-www.google.com.au-www.google.co.nz.png

Screenshots:

First URL:

First URL

Second URL:

Second URL

Image Diff:

Image Diff