From 2d4a6b2d83dfd61760dfc569265a67fea3249bdb Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Tue, 4 Apr 2017 11:29:10 -0400 Subject: avoid leaking git output for completions completions might trigger tracking of a new package. it all goes to stderr, but let's not crowd the output regardless. --- util.inc.sh | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'util.inc.sh') diff --git a/util.inc.sh b/util.inc.sh index c33cb63..ddd7592 100644 --- a/util.inc.sh +++ b/util.inc.sh @@ -36,3 +36,11 @@ in_array() { return 1 } + +quiet_git() { + local q + + [[ $ASP_GIT_QUIET ]] && q=('-q') + + command git "$1" "${q[@]}" "${@:2}" +} -- cgit v1.2.3-54-g00ecf