From f763fdc3c1dc7dfb4a7dd335df84655e347442ab Mon Sep 17 00:00:00 2001 From: "Dr. Stefan Schimanski" Date: Tue, 15 Aug 2017 09:57:45 +0200 Subject: [PATCH] Make kube::util::ensure_clean_working_dir more verbose in log files --- hack/lib/util.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/hack/lib/util.sh b/hack/lib/util.sh index cce8e40a34d..5154806ac6e 100755 --- a/hack/lib/util.sh +++ b/hack/lib/util.sh @@ -484,10 +484,12 @@ kube::util::godep_restored() { kube::util::ensure_clean_working_dir() { while ! git diff HEAD --exit-code &>/dev/null; do echo -e "\nUnexpected dirty working directory:\n" - git status -s | sed 's/^/ /' - if ! tty -s; then + if tty -s; then + git status -s + else + git diff -a # be more verbose in log files without tty exit 1 - fi + fi | sed 's/^/ /' echo -e "\nCommit your changes in another terminal and then continue here by pressing enter." read done 1>&2