# `Git.Commands.DiffFiles`
[🔗](https://github.com/joshrotenberg/git_wrapper_ex/blob/main/lib/git/commands/diff_files.ex#L1)

Implements the `Git.Command` behaviour for `git diff-files`.

Compares the files in the working tree against the index. Output is
requested with `--raw -z` and parsed into `Git.DiffRawEntry` structs.

# `t`

```elixir
@type t() :: %Git.Commands.DiffFiles{}
```

# `args`

```elixir
@spec args(t()) :: [String.t()]
```

Returns the argument list for `git diff-files`.

## Examples

    iex> Git.Commands.DiffFiles.args(%Git.Commands.DiffFiles{})
    ["diff-files", "--raw", "-z"]

# `parse_output`

```elixir
@spec parse_output(String.t(), non_neg_integer()) ::
  {:ok, [Git.DiffRawEntry.t()]} | {:error, {String.t(), non_neg_integer()}}
```

Parses the output of `git diff-files --raw -z`.

On success (exit code 0), returns `{:ok, [Git.DiffRawEntry.t()]}`.
On failure, returns `{:error, {stdout, exit_code}}`.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
