Skip to content

Zhar-anna/frontend-project-lvl2

Repository files navigation

Hexlet tests and linter status:

Actions Status

CodeClimate:

Maintainability

Test Coverage:

Test Coverage

My test:

test my project

Описание:

Вычислитель отличий это CLI программа, которая показывает различия между двумя файлами. Поддерживаемые форматы файлов: JSON, YML, YAML.

Установка:

  1. Убедитесь что у Вас установлен Node.js не ниже 12 версии: node -v.
  2. Клонируйте репозиторий: git@github.com:Zhar-anna/frontend-project-lvl2.git.
  3. Измените директорию на frontend-project-lvl2
  4. Запустите команду: make install.

Запуск тестов:

$ make test

Как использовать:

Вы можете использовать проект как скрипт в терминале или как библиотеку в Ваше проекте. Вы можете выводить изменения в трёх форматах: stylish (default), plain and json.

$ gendiff -h
Usage: gendiff [options] <filepath1> <filepath2>
Compares two configuration files and shows a difference.
Options:
  -V, --version          output the version number
  -f, --format <type>    output format (choices: "stylish", "plain", "json", default: "stylish")
  -h, --help             display help for command

Пример для файлов JSON:

asciicast

Пример для файлов YAML:

asciicast

Пример для файлов с вложенной структурой:

asciicast

Пример вывода плоского формата:

asciicast

Пример вывода в JSON формате:

asciicast

About

The Difference Calculator is a CLI program that shows the differences between two files. Supported file formats: JSON, YML, YAML.

Resources

Stars

Watchers

Forks

Packages

No packages published