From c1293b1914d410e39ae092c8054da36f2d23aa84 Mon Sep 17 00:00:00 2001 From: "Kenneth Benzie (Benie)" Date: Wed, 17 Jun 2026 13:53:53 +0100 Subject: [PATCH] Make watch git status always use color --- utilities/utilities.plugin.zsh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/utilities/utilities.plugin.zsh b/utilities/utilities.plugin.zsh index 2602c89..e7cf931 100644 --- a/utilities/utilities.plugin.zsh +++ b/utilities/utilities.plugin.zsh @@ -142,6 +142,16 @@ elif which batcat &> /dev/null; then } fi +# Wrap watch to colorize 'watch git status', otherwise pass through to the real +# watch command. +watch() { + if [ "git status" = "$*" ]; then + command watch --color -n 2 'git -c color.status=always status' + else + command watch "$@" + fi +} + if which docker-machine &> /dev/null; then # Wrap the docker command to print a message if a docker-machine is not # running, rather than just stating it can not find it's socket.