Batch compare multiple files
Run bellow command to globally install Comparator:
composer global require kduma/comparator
and add ~/.composer/vendor/bin/
directory to your PATH in your ~/.bash_profile` (or
~/.bashrc`):
export PATH=~/.composer/vendor/bin:$PATH
Execute following command:
composer global update
Usage: bin/compare [-c compare_to, --compare compare_to] [-f format, --format format] [-h, --help] [-o output, --output output] [path] [file]
Required Arguments:
path
The path with files to compare.
Optional Arguments:
-h, --help
Prints a usage statement
-c compare_to, --compare compare_to
Compare to
-f format, --format format
Output format (text or cli)
-o output, --output output
Output file for text format
file
If defined, compares specified file in subfolder.
A special thanks to creators of StringCompare, a PHP class that this package is using to compare text files.
View this package on Packagist.org: kduma/comparator