Skip to content

Instantly share code, notes, and snippets.

@oquno
Created December 1, 2009 19:28
Show Gist options
  • Save oquno/246553 to your computer and use it in GitHub Desktop.
Save oquno/246553 to your computer and use it in GitHub Desktop.
for using gyazo through kuins proxy server
begin
http = Net::HTTP.new(HOST, 80)
http.open_timeout = 2
res = http.post(CGI,data,header)
rescue Timeout::Error
http = Net::HTTP.new(HOST, 80, proxy_addr = 'proxy.kuins.net', proxy_port = 8080)
http.open_timeout = 2
res = http.post(CGI,data,header)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment