aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/formula.rb
diff options
context:
space:
mode:
authorilovezfs2018-01-19 15:07:04 -0800
committerilovezfs2018-01-19 15:07:04 -0800
commitf818f0e68139fd1e7b2665f0cd415936aa8cc63d (patch)
treee7bed4fcd2bff36886e314f9c53d63792bb92883 /Library/Homebrew/formula.rb
parentd14fd49b3062ab1d95e86b78a8228c8aee3a3304 (diff)
downloadbrew-f818f0e68139fd1e7b2665f0cd415936aa8cc63d.tar.bz2
formula: reject dot dirs as racks
Dot directories are not racks because formulae names do not start with "." so avoid attempting to descend into dot directories, which may not always be possible (e.g. .Trashes).
Diffstat (limited to 'Library/Homebrew/formula.rb')
-rw-r--r--Library/Homebrew/formula.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb
index ad7e28a2e..1355e5945 100644
--- a/Library/Homebrew/formula.rb
+++ b/Library/Homebrew/formula.rb
@@ -1371,7 +1371,7 @@ class Formula
def self.racks
@racks ||= if HOMEBREW_CELLAR.directory?
HOMEBREW_CELLAR.subdirs.reject do |rack|
- rack.symlink? || rack.subdirs.empty?
+ rack.symlink? || rack.basename.to_s.start_with?(".") || rack.subdirs.empty?
end
else
[]