diff --git a/README.md b/README.md index b2f7e74f..ed33b2ea 100644 --- a/README.md +++ b/README.md @@ -131,7 +131,13 @@ highlighting: git show v0.6.0:src/main.rs | bat -l rs ``` -Note that syntax highlighting within diffs is currently not supported. If you are looking for this, check out [`delta`](https://github.com/dandavison/delta). +#### `git diff` + +You can combine `bat` with `git diff` to view lines around code changes with proper syntax +highlighting: +```bash +git diff --name-only --diff-filter=d | xargs bat --diff +``` #### `xclip`