A demo shows how to use swig wrap libcurl for ruby.
Ruby Shell
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.gitignore
README
build.sh
curl.i
curl_test.rb
extconf.rb

README

这是一个如何通过Swig封装libcurl到ruby的演示代码

测试环境:
ruby 1.8.7
SWIG 1.3.36
libcurl 7.18.2

文件:
curl.i: swig的封装
extconf.rb: 用于生成Makefile

编译:
./build.sh

测试:
ruby curl_test.rb [URL]
例: ruby curl_test.rb http://www.google.com