From dc3b063ef6b370d1b3594ed785c682ea2db09b41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20W=C3=BChrer?= Date: Fri, 7 Apr 2023 19:25:03 +0200 Subject: Add a few incomplete things --- giteval | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100755 giteval (limited to 'giteval') diff --git a/giteval b/giteval new file mode 100755 index 0000000..c4e8d08 --- /dev/null +++ b/giteval @@ -0,0 +1,15 @@ +#!/bin/bash + +b=$(git branch --show-current 2> /dev/null) && { + case $(env - git status --no-ahead-behind | tail -n1) in + 'nothing to commit'*) + printf "\e[32m[$b]\e[0m" + ;; 'no changes added to commit'*) + printf "\e[33m[$b]\e[0m" + ;; 'nothing added to commit'*) + printf "\e[36m[$b]\e[0m" + ;; *) + printf "\e[31m[$b]\e[0m" + esac +} +echo -- cgit v1.2.3