pip3 install --upgrade git+https://github.com/mnogom/python-project-lvl2.git
- From command line
usage: gendiff [-h] [-f FORMAT] first_file second_file
Generate diff
positional arguments:
first_file
second_file
optional arguments:
-h, --help show this help message and exit
-f FORMAT, --format FORMAT
set format of output
- From python
import gendiff
style = "plain" # ["stylish (default)" | "plain" | "json"]
output = gendiff.generate_diff("path/to/file1", "path/to/file2", style)
- Works with JSON and YAML format
- Works with Plain and Recursive file structures
- Output in Stylish, Plain and JSON formats
See examples below