keg_relocate: also relocate executable text files.
There are times (e.g. `ocaml`) when the `text_executable?` test will match even although `file` does not consider it a text file. Ensure that it's relocated in this case correctly. References Homebrew/homebrew#41663. Closes Homebrew/homebrew#41926.
This commit is contained in:
parent
653053f184
commit
70739e9f05
@ -163,7 +163,10 @@ class Keg
|
||||
path.find do |pn|
|
||||
next if pn.symlink? or pn.directory?
|
||||
next if Metafiles::EXTENSIONS.include? pn.extname
|
||||
text_files << pn if Utils.popen_read("/usr/bin/file", "--brief", pn).include?("text")
|
||||
if Utils.popen_read("/usr/bin/file", "--brief", pn).include?("text") ||
|
||||
pn.text_executable?
|
||||
text_files << pn
|
||||
end
|
||||
end
|
||||
|
||||
text_files
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user