Skip to content

Latest commit

 

History

History
46 lines (44 loc) · 3.13 KB

README.md

File metadata and controls

46 lines (44 loc) · 3.13 KB

Tests and linter status:

Actions Status example workflow

Description:

This console utility can compare and calculate differences between two YAML or JSON files.

The utility has features:

  • It supports different input formats, like yaml and json.
  • You can generate a report in plain text, a "stylish" format, or as json.

Installation:

  1. git clone [email protected]:ElenaManukyan/Difference-Calculator.git
  2. make install

How to run the tests:

make test

How to run the Eslint:

make lint

How to use:

gendiff -h
Usage: gendiff [options] <filepath1> <filepath2>

Compares two configuration files and shows a difference.

Options:
  -V, --version          output the version number
  -f, --format <format>  output format (default: "stylish")
  -h, --help             display help for command

Usage examples:

Creating difference between 2 flat .json files:

Creating difference between 2 flat .yml files:

Creating difference between 2 nested .json files:

Creating difference between 2 nested .yml files:

Creating difference between 2 nested .json files with '--format plain' parameter:

Creating difference between 2 nested .yml files with '--format plain' parameter:

Creating difference between 2 nested .json files with '--format json' parameter:

Creating difference between 2 nested .yml files with '--format json' parameter: