Files comparison is a CLI-utility that compares two configuration files.
To install the utility use:
pip install -i https://test.pypi.org/simple/ krutov_gendiff
To run the utility after installing:
gendiff first_file second_file
.(You must be in the directory with the files you want to compare or specify an absolute path)
Files formats can be either .json or .yml / .yaml.
The result of comparison can also be displayed in different formats. To choose format add an optional argument --format
:
- json for json format
- plain for plain format
- default for json-like txt format. This format is used as a default.
E.g. gendiff first_file second_file --format plain
You can always call gendiff -h
for some help information.
Diff between two files (json or yaml) with text format output:
gendiff before.json after.yaml
gendiff before.json after.yaml --format text
Diff between two files (json or yaml) with plain format output:
gendiff before.json after.yaml --format plain
Diff between two files (json or yaml) with json format output:
gendiff before.json after.yaml --format json