baidu_web 0.0.1 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/baidu_web.gemspec CHANGED
@@ -10,42 +10,8 @@ Gem::Specification.new do |s|
10
10
  s.homepage = "https://github.com/krongk/baidu_web"
11
11
  s.summary = %q{baidu_web is a meta search engine for 百度(www.baidu.com)}
12
12
  s.description = %q{
13
- # Baidu_web
14
-
15
13
  Baidu_web是一个基于百度的元搜索引擎,输入关键字,返还百度搜索结果和相关的关键词;
16
14
  在线Demo: http://www.inruby.com/search
17
-
18
- ## 用法
19
-
20
- gem 'baidu_web'
21
-
22
- ## 调用
23
-
24
- # http://www.baidu.com/s?wd=inruby&pn=100&rn=50
25
- BaiduWeb.search("inruby", :per_page => 50, :page_index => 2)
26
-
27
- ## 返还结果
28
-
29
- result = BaiduWeb.search('key words')
30
- result[:record_arr].each do |record|
31
- puts record.title
32
- puts record.url
33
- puts record.summary
34
- puts record.updated_date
35
- puts record.item_index
36
- puts record.cached_url
37
- end
38
- result[:ext_key_arr].each do |ext_key|
39
- puts ext_key.title
40
- puts ext_key.url
41
- end
42
-
43
- ## 在irb中测试:
44
-
45
- $:.unshift(File.dirname(__FILE__))
46
- require 'baidu_web'
47
- require 'cgi'
48
- result = BaiduWeb.search(CGI.escape("游戏"), :per_page => 10, :page_index => 1)
49
15
  }
50
16
 
51
17
  s.rubyforge_project = "baidu_web"
@@ -1,3 +1,3 @@
1
1
  module BaiduWeb
2
- VERSION = "0.0.1"
2
+ VERSION = "0.2.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: baidu_web
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -11,18 +11,8 @@ bindir: bin
11
11
  cert_chain: []
12
12
  date: 2012-11-29 00:00:00.000000000 Z
13
13
  dependencies: []
14
- description: ! "\n # Baidu_web\n\n Baidu_web是一个基于百度的元搜索引擎,输入关键字,返还百度搜索结果和相关的关键词;\n
15
- \ 在线Demo: http://www.inruby.com/search\n \n ## 用法\n \n
16
- \ gem 'baidu_web'\n \n ## 调用\n \n # http://www.baidu.com/s?wd=inruby&pn=100&rn=50\n
17
- \ BaiduWeb.search(\"inruby\", :per_page => 50, :page_index => 2)\n \n
18
- \ ## 返还结果\n \n result = BaiduWeb.search('key words')\n result[:record_arr].each
19
- do |record|\n puts record.title\n puts record.url\n puts
20
- record.summary\n puts record.updated_date\n puts record.item_index\n
21
- \ puts record.cached_url\n end\n result[:ext_key_arr].each
22
- do |ext_key|\n puts ext_key.title\n puts ext_key.url\n end\n
23
- \ \n ## 在irb中测试:\n \n $:.unshift(File.dirname(__FILE__))\n
24
- \ require 'baidu_web'\n require 'cgi'\n result =
25
- BaiduWeb.search(CGI.escape(\"游戏\"), :per_page => 10, :page_index => 1)\n "
14
+ description: ! "\n Baidu_web是一个基于百度的元搜索引擎,输入关键字,返还百度搜索结果和相关的关键词;\n 在线Demo:
15
+ http://www.inruby.com/search\n "
26
16
  email:
27
17
  - kenrome@gmail.com
28
18
  executables: []