diff options
author | Carlo Sala <carlosalag@protonmail.com> | 2023-01-25 08:50:06 +0100 |
---|---|---|
committer | Carlo Sala <carlosalag@protonmail.com> | 2023-01-25 18:12:20 +0100 |
commit | 657ad0523d5a29e0bdc8af0cd63c23ac597406e8 (patch) | |
tree | 99c19dcc33c68963c54121a6566be5fa0bd6d20c /lib | |
parent | 7de55844b26394688221b1cd12ef4053b3c7f6c7 (diff) | |
download | zsh-657ad0523d5a29e0bdc8af0cd63c23ac597406e8.tar.gz zsh-657ad0523d5a29e0bdc8af0cd63c23ac597406e8.tar.bz2 zsh-657ad0523d5a29e0bdc8af0cd63c23ac597406e8.zip |
fix(theme-and-appearance): fix `diff` completion in macOS
Closes #11416
Closes #11454
Diffstat (limited to 'lib')
-rw-r--r-- | lib/theme-and-appearance.zsh | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/theme-and-appearance.zsh b/lib/theme-and-appearance.zsh index 00947f72d..9b908bef0 100644 --- a/lib/theme-and-appearance.zsh +++ b/lib/theme-and-appearance.zsh @@ -41,7 +41,11 @@ fi # enable diff color if possible. if command diff --color /dev/null /dev/null &>/dev/null; then - alias diff='diff --color' + function color-diff { + diff --color $@ + } + alias diff="color-diff" + compdef _diff color-diff # compdef is already loaded by this point fi setopt auto_cd |