We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents efe4389 + e37cfd4 commit 6f08698Copy full SHA for 6f08698
ruby/private/binary_wrapper.tpl
@@ -23,7 +23,7 @@ require 'rbconfig'
23
# Ruby 2.4 and older does not have +.children+
24
# So we define it.
25
unless Dir.respond_to?(:children)
26
- Dir.define_method :children do |dir|
+ Dir.class.send :define_method, :children do |dir|
27
Dir.entries(dir).reject { |entry| %w(. ..).include?(entry) }
28
end
29
@@ -52,7 +52,8 @@ def create_loadpath_entries(custom, runfiles)
52
53
54
def get_repository_imports(runfiles)
55
- Dir.children(runfiles).map {|d|
+ children = Dir.entries(runfiles) - [".", ".."]
56
+ children.map {|d|
57
File.join(runfiles, d)
58
}.select {|d|
59
File.directory? d
0 commit comments