yamldiff icon indicating copy to clipboard operation
yamldiff copied to clipboard

A CLI tool to diff two YAML files.

Results 10 yamldiff issues
Sort by recently updated
recently updated
newest added

Fixes https://github.com/sahilm/yamldiff/issues/7 by pulling out `kylelemons/godebug/pretty` and using `r3labs/diff` to generate the diff instead. This enables printing a path before the diff. Example output: ![image](https://user-images.githubusercontent.com/4432772/87983225-0970f100-caa6-11ea-9516-dd93076282f9.png) I hope this is valuable...

Readme file gives yamldiff --file1 /path/to/yamlfile1.yml --file2 /path/to/yamlfile2.yml as an example. Given that I assume every invocation requires two files as input, maybe yamldiff /path/to/yamlfile1.yml /path/to/yamlfile2.yml (similar to good'ole `diff`)...

I just arrived here and would be curious to see what the output looks like.

From what I understand, [`stat(...)`](https://github.com/sahilm/yamldiff/blob/master/main.go#L60) is only used to check that a file exist. But really, https://github.com/sahilm/yamldiff/blob/3a067f14615afd8347b396a24cd800810bcec41f/main.go#L45-L52 will fail if any of the files don't exist. Additionally, https://github.com/sahilm/yamldiff/blob/master/main.go#L80 will fail...

I've found this very handy for a few diffs, where the structure lets me easily identify the changed lines, but it's trickier when there are similar sections. Example output chunk...

It would be useful to leverage the program return code to determine whether or not inputs have differences.

Yamldiff suffers from a type coercion bug/feature from the underlying godebug library: https://github.com/kylelemons/godebug/issues/21 Example files: ``` 0.123: "a value" ``` ``` "0.123": "a value" ``` These two will have no...

This PR removes the need for the --file1 and --file2 options and uses the remaining command line arguments, this allows a more natural command: `yamldiff file1 file2`

It would be awesome if this tool was distributed as a Homebrew package. I'd love to be able to do something like this: ``` brew install yamldiff ```

Would allow others to use this as a library in their own CLI by providing 2 files and a noColor flag.