Skip to content

Diff contents regions of HTML documents using CSS selectors. Pretty diff formatted output.

Notifications You must be signed in to change notification settings

guacamoly/htmldiff2

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

usage: htmldiff2.py [-h] [--show-config-format] [-t THREADS] [--debug] config

    Use htmldiff2.py for diffing HTML served from the same path on different servers.
    This is useful when you want to find differences between production and
    staging environments.

examle usage: ./htmldiff2.py example_configs/reddit_vs_reddit_beta.json

positional arguments:

  config                JSON config file. See below for config schema.

optional arguments:

  -h, --help            show this help message and exit
  --show-config-format  show the config format
  -t THREADS, --threads THREADS
                        set the number of threads
  --debug               disable threading for debug purposes

JSON config file schema:

{
    "title": "htmldiff config",
    "type": "object",
    "properties": {
        "servers": {
            "type": "array",
            "items": {
                "type": "object",
                "properties": {
                    "base_url": {"type": "string"},
                    "auth": {
                        "type": "array",
                        "items": { "type": "string" }
                    },
                    "protocol": {"type" : "string"}
                },
                "required": ["base_url"]
            }
        },
        "relative_urls": {
            "type": "array",
            "minItems": 1,
            "items": { "type": "string" },
            "uniqueItems": true
        },
        "selectors": { "type": "object" }
    },
    "required": ["servers", "relative_urls", "selectors"]
}

About

Diff contents regions of HTML documents using CSS selectors. Pretty diff formatted output.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%