End of Life Ruby 3.2 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
class method
Net::HTTP.get_print
Net::HTTP.get_print(hostname, path, port = 80) → nil
Net::HTTP:get_print(uri, headers = {}, port = uri.port) → nil
lib/net/http.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.2.0/lib/net/http.rb, line 419
def HTTP.get_print(uri_or_host, path_or_headers = nil, port = nil)
get_response(uri_or_host, path_or_headers, port) {|res|
res.read_body do |chunk|
$stdout.print chunk
end
}
nil
end
Like Net::HTTP.get, but writes the returned body to $stdout; returns nil.
See also
.get
.get_response
.default_port
.http_default_port
also in
4.1 · 4.0 · 3.4 · 3.3 · 3.1 · 3.0