Preview Ruby 4.1 is a preview. It can change before the final release. Switch to Ruby 4.0 →
instance method
Gem::SpecificationPolicy#validate_executable
validate_executable(executable)
lib/rubygems/specification_policy.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.1.0-preview1/lib/rubygems/specification_policy.rb, line 452
def validate_executable(executable)
separators = [File::SEPARATOR, File::ALT_SEPARATOR, File::PATH_SEPARATOR].compact.map {|sep| Regexp.escape(sep) }.join
return unless executable.match?(/[\s#{separators}]/)
error "executable \"#{executable}\" contains invalid characters"
end
No documentation available