summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Wu <lekensteyn@gmail.com>2013-11-22 19:57:55 +0100
committerPeter Wu <lekensteyn@gmail.com>2013-11-22 19:57:55 +0100
commit0aead04cb732d55c584c1235dd59d15a02d54461 (patch)
tree5a183c4f280b54d1acd567f01003e7499b25afd5
parentca85432c68099397aeb60b0f9fd1ca9186c4c8b5 (diff)
downloadscripts-0aead04cb732d55c584c1235dd59d15a02d54461.tar.gz
git-log-describe: stop color on line
To avoid funny color effects when doing: git log --color | git-log-describe.awk | less -RN
-rwxr-xr-xgit-log-describe.awk3
1 files changed, 2 insertions, 1 deletions
diff --git a/git-log-describe.awk b/git-log-describe.awk
index 9bb5896..579b06d 100755
--- a/git-log-describe.awk
+++ b/git-log-describe.awk
@@ -31,6 +31,7 @@ $1 == "commit" && $2 ~ /^[0-9a-f]{5,40}$/ {
printf("%" indent_len "sDescribe: ", "");
if (is_color) printf("\033[96m"); # light cyan
- system("git describe --first-parent " hash);# " |tr -d '\''\n'\''");
+ system("git describe --first-parent " hash " | tr -d '\n'");
if (is_color) printf("\033[m");
+ printf("\n");
}