From 32f2231cdf8a930f9c7366ee7ac7e0258a54fb9b Mon Sep 17 00:00:00 2001 From: Josh Hagins Date: Wed, 19 Oct 2016 19:39:11 -0400 Subject: hbc/cli/list: don't require Caskroom to be initialized --- Library/Homebrew/cask/lib/hbc/cli/list.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/cask/lib/hbc/cli/list.rb b/Library/Homebrew/cask/lib/hbc/cli/list.rb index 330c81b90..4557515f4 100644 --- a/Library/Homebrew/cask/lib/hbc/cli/list.rb +++ b/Library/Homebrew/cask/lib/hbc/cli/list.rb @@ -83,7 +83,7 @@ module Hbc end def self.needs_init? - true + false end end end -- cgit v1.2.3 From 3bc2c2d087a27c1cb67c727afd8ad88ce97167b2 Mon Sep 17 00:00:00 2001 From: Josh Hagins Date: Wed, 19 Oct 2016 19:39:39 -0400 Subject: hbc/cli/list: don't print empty line if nothing to list --- Library/Homebrew/cask/lib/hbc/cli/list.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/cask/lib/hbc/cli/list.rb b/Library/Homebrew/cask/lib/hbc/cli/list.rb index 4557515f4..4094b3d38 100644 --- a/Library/Homebrew/cask/lib/hbc/cli/list.rb +++ b/Library/Homebrew/cask/lib/hbc/cli/list.rb @@ -67,7 +67,7 @@ module Hbc puts installed_casks.map(&:to_s) elsif @options[:versions] puts installed_casks.map(&method(:format_versioned)) - else + elsif !installed_casks.empty? puts Formatter.columns(installed_casks.map(&:to_s)) end -- cgit v1.2.3