fidilly/gendiff

This library calculates and shows the difference between json or yaml file formats.

3.0.3 2019-08-18 16:39 UTC

This package is auto-updated.

Last update: 2024-04-19 03:14:19 UTC


README

Maintainability Test Coverage Build Status

Gendiff is a library for comparing json or yaml file formats. This library calculates and shows the difference between files.

Installation

Gendiff can be installed globally with Composer or included in a project or library.

Global installation:

composer global require fidilly/gendiff

example:

asciicast

Include:

composer require fidilly/gendiff
use function Differ\Gendiff\gendiff;

gendiff($pathToFile1, $pathToFile2, $format);

Usage via terminal

Help call examples:

gendiff -h
gendiff --help

Gendiff supports multiple output formats.

examples:

gendiff <file1> <file2> ###default 'pretty' format
gendiff --format pretty <file1> <file2>
gendiff --format plain <file1> <file2>
gendiff --format json <file1> <file2>

Usage examples

asciicast

asciicast

asciicast

asciicast

asciicast