From a7b38fc71248067a60532a3bbd9ae98611e97b55 Mon Sep 17 00:00:00 2001 From: Dominik Richter Date: Thu, 21 Sep 2023 21:20:21 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20avoid=20printing=20home-path=20f?= =?UTF-8?q?or=20root?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Root just uses the system path, so trying to print a home path that is an empty string is confusing and wrong. Signed-off-by: Dominik Richter --- apps/cnquery/cmd/providers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/cnquery/cmd/providers.go b/apps/cnquery/cmd/providers.go index 812e25511f..9272128e22 100644 --- a/apps/cnquery/cmd/providers.go +++ b/apps/cnquery/cmd/providers.go @@ -153,7 +153,7 @@ func printProviders(p []*providers.Provider) { func printProviderPath(path string, list []*providers.Provider, printEmpty bool) { if list == nil { - if printEmpty { + if printEmpty && path != "" { fmt.Println("") log.Info().Msg(path + " has no providers") }