Skip to content
Snippets Groups Projects
Commit d9c586e2 authored by Jack Nagel's avatar Jack Nagel
Browse files

Remove unnecessary string evals from doctor

parent c4cdd2b7
No related branches found
No related tags found
No related merge requests found
......@@ -377,20 +377,19 @@ def check_access_usr_local
end
%w{include etc lib lib/pkgconfig share}.each do |d|
class_eval <<-EOS, __FILE__, __LINE__ + 1
def check_access_#{d.sub("/", "_")}
if (dir = HOMEBREW_PREFIX+'#{d}').exist? && !dir.writable_real?
<<-EOF.undent
\#{dir} isn't writable.
This can happen if you "sudo make install" software that isn't managed by
by Homebrew. If a brew tries to write a file to this directory, the
install will fail during the link step.
You should probably `chown` \#{dir}
EOF
end
define_method("check_access_#{d.sub("/", "_")}") do
dir = HOMEBREW_PREFIX.join(d)
if dir.exist? && !dir.writable_real? then <<-EOS.undent
#{dir} isn't writable.
This can happen if you "sudo make install" software that isn't managed by
by Homebrew. If a formula tries to write a file to this directory, the
install will fail during the link step.
You should probably `chown` #{dir}
EOS
end
EOS
end
end
def check_access_logs
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment