arkadiy / php-project2
There is no license information available for the latest version (0.1.3) of this package.
A command-line tool educational project
0.1.3
2019-07-13 13:31 UTC
Requires
- docopt/docopt: ^1.0
- funct/funct: ^1.5
- phpunit/phpunit: ^7.5
- symfony/yaml: ^4.3
- tightenco/collect: ^5.8
Requires (Dev)
README
Description
A command line utility for generating differences between two configurational files. Supporting file formats:
- json
- yaml
This is an educational project for hexlet.
Installation
In order to install and run the utility:
composer global require arkadiy/php-project2
Usage
gendiff -h
Generate diff
Usage:
gendiff (-h|--help)
gendiff [--format <fmt>] <firstFile> <secondFile>
Options:
-h --help Show this screen
--format <fmt> Report format [default: pretty]
It is possible to run the utility directly in the terminal with the command:
composer global require arkadiy/php-project2
It is possible to use the code as a library as well:
use function \Gendiff\genDiff;
Supported config formats
This util supports two different configuration files formats:
- json
- yaml
JSON
YAML
Deep nested configurational files
The util is able to read config files with deep nesting also.
Output formats
The output formats are 3:
- pretty (default format, example is shown in previous videp)
- plain
- json
PLAIN FORMAT
JSON FORMAT
Tests
This project includes unit testing. It is possible to run the tests with:
make test