radiant-ray-extension 3.0.0.alpha → 3.0.0.pre

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. data/README.markdown +1 -1
  2. data/Rakefile +2 -0
  3. data/doc/NilClass.html +178 -0
  4. data/doc/Ray/CLI.html +211 -197
  5. data/doc/Ray/Extension/Git.html +435 -0
  6. data/doc/Ray/Extension/RubyGem.html +858 -0
  7. data/doc/Ray/Extension/Zip.html +453 -0
  8. data/doc/Ray/Extension.html +755 -0
  9. data/doc/Ray/{Cache.html → Search/Cache.html} +108 -256
  10. data/doc/Ray/{GitHub.html → Search/GitHub.html} +167 -81
  11. data/doc/Ray/{RubyGems.html → Search/RubyGems.html} +118 -68
  12. data/doc/Ray/Search.html +822 -0
  13. data/doc/Ray.html +89 -34
  14. data/doc/String.html +99 -29
  15. data/doc/_index.html +1 -1
  16. data/doc/file.LICENSE.html +1 -1
  17. data/doc/file.README.html +2 -4
  18. data/doc/index.html +1 -1
  19. data/doc/top-level-namespace.html +3 -3
  20. data/lib/ray/cli.rb +146 -193
  21. data/lib/ray/constants.rb +7 -12
  22. data/lib/ray/extension.rb +203 -89
  23. data/lib/ray/search.rb +198 -43
  24. data/lib/ray/utility.rb +31 -0
  25. data/lib/ray.rb +2 -7
  26. data/spec/fixtures/cache_single.yml +2 -1
  27. data/spec/fixtures/cassettes/combined_search_empty.yml +71 -0
  28. data/spec/fixtures/cassettes/combined_search_multiple.yml +264 -0
  29. data/spec/fixtures/cassettes/combined_search_single.yml +108 -0
  30. data/spec/fixtures/cassettes/github_reorder_children_zip_file.yml +487 -0
  31. data/spec/fixtures/cassettes/github_sitemap_xml_zip_file.yml +553 -0
  32. data/spec/fixtures/cassettes/{github_v2_api_no_matches.yml → github_v2_search_empty.yml} +3 -3
  33. data/spec/fixtures/cassettes/github_v2_search_multiple.yml +225 -0
  34. data/spec/fixtures/cassettes/github_v2_search_single.yml +76 -0
  35. data/spec/fixtures/cassettes/{zip_file.yml → github_zip_file.yml} +3 -3
  36. data/spec/fixtures/cassettes/{rubygems_v1_api_gem_info.yml → rubygems_v1_gem_info.yml} +5 -5
  37. data/spec/fixtures/cassettes/{rubygems_v1_api_no_matches.yml → rubygems_v1_search_empty.yml} +3 -3
  38. data/spec/fixtures/cassettes/rubygems_v1_search_multiple.yml +40 -0
  39. data/spec/fixtures/cassettes/{rubygems_v1_api_search_reorder_children.yml → rubygems_v1_search_single.yml} +6 -6
  40. data/spec/fixtures/dummy.zip +0 -0
  41. data/spec/ray/extension_spec.rb +172 -0
  42. data/spec/ray/search_spec.rb +300 -0
  43. data/spec/spec_helper.rb +36 -9
  44. metadata +50 -85
  45. data/doc/Extension.html +0 -1189
  46. data/doc/Ray/Gem.html +0 -760
  47. data/doc/Ray/Git.html +0 -278
  48. data/doc/Ray/Zip.html +0 -300
  49. data/doc/Search.html +0 -433
  50. data/lib/ray/extension/gem.rb +0 -96
  51. data/lib/ray/extension/git.rb +0 -30
  52. data/lib/ray/extension/zip.rb +0 -44
  53. data/lib/ray/search/cache.rb +0 -61
  54. data/lib/ray/search/github.rb +0 -40
  55. data/lib/ray/search/rubygems.rb +0 -36
  56. data/lib/ray/string.rb +0 -18
  57. data/spec/fixtures/Gemfile +0 -4
  58. data/spec/fixtures/cassettes/github_v2_api_search_no_matches.yml +0 -38
  59. data/spec/fixtures/cassettes/github_v2_api_search_reorder_children.yml +0 -75
  60. data/spec/fixtures/cassettes/github_v2_api_search_single.yml +0 -74
  61. data/spec/fixtures/cassettes/github_v3_api_owner_name.yml +0 -75
  62. data/spec/fixtures/cassettes/rubygems_v1_api_search_no_matches.yml +0 -34
  63. data/spec/fixtures/cassettes/rubygems_v1_api_search_reorder.yml +0 -36
  64. data/spec/fixtures/cassettes/rubygems_v1_api_search_single.yml +0 -41
  65. data/spec/fixtures/dummy/README +0 -1
  66. data/spec/fixtures/dummy/Rakefile +0 -109
  67. data/spec/fixtures/dummy/config/initializers/radiant_config.rb +0 -3
  68. data/spec/fixtures/dummy/config/locales/en.yml +0 -3
  69. data/spec/fixtures/dummy/config/routes.rb +0 -5
  70. data/spec/fixtures/dummy/dummy_extension.rb +0 -21
  71. data/spec/fixtures/dummy/lib/radiant-dummy-extension.rb +0 -8
  72. data/spec/fixtures/dummy/lib/tasks/dummy_extension_tasks.rake +0 -47
  73. data/spec/fixtures/dummy/public/stylesheets/extensions/dummy/dummy.css +0 -0
  74. data/spec/fixtures/dummy/radiant-dummy-extension.gemspec +0 -29
  75. data/spec/ray/extension/gem_spec.rb +0 -214
  76. data/spec/ray/extension/git_spec.rb +0 -216
  77. data/spec/ray/extension/zip_spec.rb +0 -239
  78. data/spec/ray/search/cache_spec.rb +0 -74
  79. data/spec/ray/search/github_spec.rb +0 -137
  80. data/spec/ray/search/rubygems_spec.rb +0 -127
  81. data/spec/ray/string_spec.rb +0 -30
@@ -4,24 +4,24 @@
4
4
  <head>
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>
7
- Class: Ray::GitHub
7
+ Class: Ray::Search::GitHub
8
8
 
9
9
  &mdash; Documentation by YARD 0.7.3
10
10
 
11
11
  </title>
12
12
 
13
- <link rel="stylesheet" href="../css/style.css" type="text/css" media="screen" charset="utf-8" />
13
+ <link rel="stylesheet" href="../../css/style.css" type="text/css" media="screen" charset="utf-8" />
14
14
 
15
- <link rel="stylesheet" href="../css/common.css" type="text/css" media="screen" charset="utf-8" />
15
+ <link rel="stylesheet" href="../../css/common.css" type="text/css" media="screen" charset="utf-8" />
16
16
 
17
17
  <script type="text/javascript" charset="utf-8">
18
- relpath = '..';
18
+ relpath = '../..';
19
19
  if (relpath != '') relpath += '/';
20
20
  </script>
21
21
 
22
- <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
22
+ <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
23
23
 
24
- <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
24
+ <script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
25
25
 
26
26
 
27
27
  </head>
@@ -33,8 +33,8 @@
33
33
  <div id="header">
34
34
  <div id="menu">
35
35
 
36
- <a href="../_index.html">Index (G)</a> &raquo;
37
- <span class='title'><span class='object_link'><a href="../Ray.html" title="Ray (module)">Ray</a></span></span>
36
+ <a href="../../_index.html">Index (G)</a> &raquo;
37
+ <span class='title'><span class='object_link'><a href="../../Ray.html" title="Ray (module)">Ray</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../Search.html" title="Ray::Search (class)">Search</a></span></span>
38
38
  &raquo;
39
39
  <span class="title">GitHub</span>
40
40
 
@@ -56,7 +56,7 @@
56
56
 
57
57
  <iframe id="search_frame"></iframe>
58
58
 
59
- <div id="content"><h1>Class: Ray::GitHub
59
+ <div id="content"><h1>Class: Ray::Search::GitHub
60
60
 
61
61
 
62
62
 
@@ -66,12 +66,14 @@
66
66
 
67
67
  <dt class="r1">Inherits:</dt>
68
68
  <dd class="r1">
69
- <span class="inheritName">Object</span>
69
+ <span class="inheritName"><span class='object_link'><a href="../Search.html" title="Ray::Search (class)">Ray::Search</a></span></span>
70
70
 
71
71
  <ul class="fullTree">
72
72
  <li>Object</li>
73
73
 
74
- <li class="next">Ray::GitHub</li>
74
+ <li class="next"><span class='object_link'><a href="../Search.html" title="Ray::Search (class)">Ray::Search</a></span></li>
75
+
76
+ <li class="next">Ray::Search::GitHub</li>
75
77
 
76
78
  </ul>
77
79
  <a href="#" class="inheritanceTree">show all</a>
@@ -83,21 +85,27 @@
83
85
 
84
86
 
85
87
 
86
- <dt class="r2">Includes:</dt>
87
- <dd class="r2"><span class='object_link'><a href="../Search.html" title="Search (module)">Search</a></span></dd>
88
-
89
-
90
88
 
91
89
 
92
90
 
93
- <dt class="r1 last">Defined in:</dt>
94
- <dd class="r1 last">lib/ray/search/github.rb</dd>
91
+ <dt class="r2 last">Defined in:</dt>
92
+ <dd class="r2 last">lib/ray/search.rb</dd>
95
93
 
96
94
  </dl>
97
95
  <div class="clear"></div>
98
96
 
97
+ <h2>Overview</h2><div class="docstring">
98
+ <div class="discussion">
99
+ <p>Search GitHub for extension information</p>
99
100
 
100
101
 
102
+ </div>
103
+ </div>
104
+ <div class="tags">
105
+
106
+
107
+ </div>
108
+
101
109
 
102
110
 
103
111
 
@@ -187,6 +195,11 @@
187
195
 
188
196
 
189
197
 
198
+
199
+
200
+ <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="../Search.html" title="Ray::Search (class)">Ray::Search</a></span></h3>
201
+ <p class="inherited"><span class='object_link'><a href="../Search.html#query-instance_method" title="Ray::Search#query (method)">query</a></span>, <span class='object_link'><a href="../Search.html#results-instance_method" title="Ray::Search#results (method)">results</a></span>, <span class='object_link'><a href="../Search.html#uri-instance_method" title="Ray::Search#uri (method)">uri</a></span></p>
202
+
190
203
 
191
204
 
192
205
  <h2>
@@ -199,7 +212,7 @@
199
212
  <li class="public ">
200
213
  <span class="summary_signature">
201
214
 
202
- <a href="#initialize-instance_method" title="#initialize (instance method)">- (GitHub) <strong>initialize</strong>(query) </a>
215
+ <a href="#initialize-instance_method" title="#initialize (instance method)">- (GitHub) <strong>initialize</strong>(query = nil) </a>
203
216
 
204
217
 
205
218
 
@@ -223,7 +236,7 @@
223
236
  <li class="public ">
224
237
  <span class="summary_signature">
225
238
 
226
- <a href="#normalize-instance_method" title="#normalize (instance method)">- (Object) <strong>normalize</strong>(response) </a>
239
+ <a href="#normalize-instance_method" title="#normalize (instance method)">- (Hash) <strong>normalize</strong>(response) </a>
227
240
 
228
241
 
229
242
 
@@ -236,7 +249,7 @@
236
249
 
237
250
 
238
251
 
239
- <span class="summary_desc"><div class='inline'>
252
+ <span class="summary_desc"><div class='inline'><p>Normalize GitHub JSON response.</p>
240
253
  </div></span>
241
254
 
242
255
  </li>
@@ -245,7 +258,7 @@
245
258
  <li class="public ">
246
259
  <span class="summary_signature">
247
260
 
248
- <a href="#real_name-instance_method" title="#real_name (instance method)">- (Object) <strong>real_name</strong>(owner) </a>
261
+ <a href="#real_name-instance_method" title="#real_name (instance method)">- (String) <strong>real_name</strong>(owner) </a>
249
262
 
250
263
 
251
264
 
@@ -258,7 +271,7 @@
258
271
 
259
272
 
260
273
 
261
- <span class="summary_desc"><div class='inline'>
274
+ <span class="summary_desc"><div class='inline'><p>Use GitHub API v3 to look up the owner&rsquo;s real name.</p>
262
275
  </div></span>
263
276
 
264
277
  </li>
@@ -275,15 +288,15 @@
275
288
 
276
289
 
277
290
 
278
- <h3 class="inherited">Methods included from <span class='object_link'><a href="../Search.html" title="Search (module)">Search</a></span></h3>
279
- <p class="inherited"><span class='object_link'><a href="../Search.html#cache-instance_method" title="Search#cache (method)">#cache</a></span>, <span class='object_link'><a href="../Search.html#merge-instance_method" title="Search#merge (method)">#merge</a></span>, <span class='object_link'><a href="../Search.html#multiple_choice-instance_method" title="Search#multiple_choice (method)">#multiple_choice</a></span>, <span class='object_link'><a href="../Search.html#output-instance_method" title="Search#output (method)">#output</a></span>, <span class='object_link'><a href="../Search.html#search-instance_method" title="Search#search (method)">#search</a></span></p>
291
+ <h3 class="inherited">Methods inherited from <span class='object_link'><a href="../Search.html" title="Ray::Search (class)">Ray::Search</a></span></h3>
292
+ <p class="inherited"><span class='object_link'><a href="../Search.html#cache-instance_method" title="Ray::Search#cache (method)">#cache</a></span>, <span class='object_link'><a href="../Search.html#multiple_choice-instance_method" title="Ray::Search#multiple_choice (method)">#multiple_choice</a></span>, <span class='object_link'><a href="../Search.html#output-instance_method" title="Ray::Search#output (method)">#output</a></span>, <span class='object_link'><a href="../Search.html#search-instance_method" title="Ray::Search#search (method)">#search</a></span></p>
280
293
  <div id="constructor_details" class="method_details_list">
281
294
  <h2>Constructor Details</h2>
282
295
 
283
296
  <div class="method_details first">
284
297
  <p class="signature first" id="initialize-instance_method">
285
298
 
286
- - (<tt><span class='object_link'><a href="" title="Ray::GitHub (class)">GitHub</a></span></tt>) <strong>initialize</strong>(query)
299
+ - (<tt><span class='object_link'><a href="" title="Ray::Search::GitHub (class)">GitHub</a></span></tt>) <strong>initialize</strong>(query = nil)
287
300
 
288
301
 
289
302
 
@@ -303,19 +316,27 @@
303
316
  <pre class="lines">
304
317
 
305
318
 
306
- 11
307
- 12
308
- 13
309
- 14
310
- 15</pre>
319
+ 132
320
+ 133
321
+ 134
322
+ 135
323
+ 136
324
+ 137
325
+ 138
326
+ 139
327
+ 140</pre>
311
328
  </td>
312
329
  <td>
313
- <pre class="code"><span class="info file"># File 'lib/ray/search/github.rb', line 11</span>
314
-
315
- <span class='kw'>def</span> <span class='id initialize'>initialize</span> <span class='id query'>query</span>
316
- <span class='ivar'>@query</span> <span class='op'>=</span> <span class='id query'>query</span>
317
- <span class='ivar'>@uri</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span><span class='const'>Ray</span><span class='op'>::</span><span class='const'>GH_V2_API</span><span class='rbrace'>}</span><span class='tstring_content'>/repos/search/radiant+</span><span class='embexpr_beg'>#{</span><span class='ivar'>@query</span><span class='rbrace'>}</span><span class='tstring_end'>&quot;</span></span>
318
- <span class='ivar'>@results</span> <span class='op'>=</span> <span class='id search'>search</span>
330
+ <pre class="code"><span class="info file"># File 'lib/ray/search.rb', line 132</span>
331
+
332
+ <span class='kw'>def</span> <span class='id initialize'>initialize</span> <span class='id query'>query</span> <span class='op'>=</span> <span class='kw'>nil</span>
333
+ <span class='kw'>if</span> <span class='id query'>query</span>
334
+ <span class='ivar'>@query</span> <span class='op'>=</span> <span class='id query'>query</span>
335
+ <span class='ivar'>@uri</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>http://github.com/api/v2/json/repos/search/radiant+</span><span class='embexpr_beg'>#{</span><span class='id query'>query</span><span class='rbrace'>}</span><span class='tstring_end'>&quot;</span></span>
336
+ <span class='ivar'>@results</span> <span class='op'>=</span> <span class='id search'>search</span>
337
+ <span class='kw'>else</span>
338
+ <span class='ivar'>@results</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>A search query is required. Try: ray help search</span><span class='tstring_end'>&quot;</span></span>
339
+ <span class='kw'>end</span>
319
340
  <span class='kw'>end</span></pre>
320
341
  </td>
321
342
  </tr>
@@ -353,12 +374,12 @@
353
374
  <pre class="lines">
354
375
 
355
376
 
356
- 9
357
- 10
358
- 11</pre>
377
+ 128
378
+ 129
379
+ 130</pre>
359
380
  </td>
360
381
  <td>
361
- <pre class="code"><span class="info file"># File 'lib/ray/search/github.rb', line 9</span>
382
+ <pre class="code"><span class="info file"># File 'lib/ray/search.rb', line 128</span>
362
383
 
363
384
  <span class='kw'>def</span> <span class='id query'>query</span>
364
385
  <span class='ivar'>@query</span>
@@ -394,12 +415,12 @@
394
415
  <pre class="lines">
395
416
 
396
417
 
397
- 9
398
- 10
399
- 11</pre>
418
+ 128
419
+ 129
420
+ 130</pre>
400
421
  </td>
401
422
  <td>
402
- <pre class="code"><span class="info file"># File 'lib/ray/search/github.rb', line 9</span>
423
+ <pre class="code"><span class="info file"># File 'lib/ray/search.rb', line 128</span>
403
424
 
404
425
  <span class='kw'>def</span> <span class='id results'>results</span>
405
426
  <span class='ivar'>@results</span>
@@ -435,12 +456,12 @@
435
456
  <pre class="lines">
436
457
 
437
458
 
438
- 9
439
- 10
440
- 11</pre>
459
+ 128
460
+ 129
461
+ 130</pre>
441
462
  </td>
442
463
  <td>
443
- <pre class="code"><span class="info file"># File 'lib/ray/search/github.rb', line 9</span>
464
+ <pre class="code"><span class="info file"># File 'lib/ray/search.rb', line 128</span>
444
465
 
445
466
  <span class='kw'>def</span> <span class='id uri'>uri</span>
446
467
  <span class='ivar'>@uri</span>
@@ -460,46 +481,75 @@
460
481
  <div class="method_details first">
461
482
  <p class="signature first" id="normalize-instance_method">
462
483
 
463
- - (<tt>Object</tt>) <strong>normalize</strong>(response)
484
+ - (<tt>Hash</tt>) <strong>normalize</strong>(response)
464
485
 
465
486
 
466
487
 
467
- </p><table class="source_code">
488
+ </p><div class="docstring">
489
+ <div class="discussion">
490
+ <p>Normalize GitHub JSON response</p>
491
+
492
+
493
+ </div>
494
+ </div>
495
+ <div class="tags">
496
+
497
+ <h3>Returns:</h3>
498
+ <ul class="return">
499
+
500
+ <li>
501
+
502
+
503
+ <span class='type'>(<tt>Hash</tt>)</span>
504
+
505
+
506
+
507
+ &mdash;
508
+ <div class='inline'><p>search results in a normalized format</p>
509
+ </div>
510
+
511
+ </li>
512
+
513
+ </ul>
514
+
515
+ </div><table class="source_code">
468
516
  <tr>
469
517
  <td>
470
518
  <pre class="lines">
471
519
 
472
520
 
473
- 17
474
- 18
475
- 19
476
- 20
477
- 21
478
- 22
479
- 23
480
- 24
481
- 25
482
- 26
483
- 27
484
- 28
485
- 29
486
- 30
487
- 31</pre>
521
+ 144
522
+ 145
523
+ 146
524
+ 147
525
+ 148
526
+ 149
527
+ 150
528
+ 151
529
+ 152
530
+ 153
531
+ 154
532
+ 155
533
+ 156
534
+ 157
535
+ 158
536
+ 159</pre>
488
537
  </td>
489
538
  <td>
490
- <pre class="code"><span class="info file"># File 'lib/ray/search/github.rb', line 17</span>
539
+ <pre class="code"><span class="info file"># File 'lib/ray/search.rb', line 144</span>
491
540
 
492
541
  <span class='kw'>def</span> <span class='id normalize'>normalize</span> <span class='id response'>response</span>
493
542
  <span class='id response'>response</span> <span class='op'>=</span> <span class='const'>MultiJson</span><span class='period'>.</span><span class='id decode'>decode</span> <span class='id response'>response</span>
494
543
  <span class='id results'>results</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
495
544
  <span class='id response'>response</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>repositories</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id extension'>extension</span><span class='op'>|</span>
496
545
  <span class='id results'>results</span><span class='lbracket'>[</span><span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>name</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id to_extension_name'>to_extension_name</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='lbrace'>{</span>
497
- <span class='symbol'>:author</span> <span class='op'>=&gt;</span> <span class='id real_name'>real_name</span><span class='lparen'>(</span><span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>owner</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='comma'>,</span>
498
- <span class='symbol'>:description</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>description</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span>
499
- <span class='symbol'>:homepage</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>url</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span>
500
- <span class='symbol'>:name</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>name</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id to_extension_name'>to_extension_name</span><span class='comma'>,</span>
501
- <span class='symbol'>:uri</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>url</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span>
502
- <span class='symbol'>:version</span> <span class='op'>=&gt;</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>latest</span><span class='tstring_end'>&quot;</span></span>
546
+ <span class='symbol'>:author</span> <span class='op'>=&gt;</span> <span class='id real_name'>real_name</span><span class='lparen'>(</span><span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>owner</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='comma'>,</span>
547
+ <span class='symbol'>:description</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>description</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span>
548
+ <span class='symbol'>:homepage</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>url</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='comma'>,</span>
549
+ <span class='symbol'>:name</span> <span class='op'>=&gt;</span> <span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>name</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id to_extension_name'>to_extension_name</span><span class='comma'>,</span>
550
+ <span class='symbol'>:repository</span> <span class='op'>=&gt;</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span><span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>url</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>.git</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span>
551
+ <span class='symbol'>:uri</span> <span class='op'>=&gt;</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span><span class='id extension'>extension</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>url</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>/zipball/master</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span>
552
+ <span class='symbol'>:version</span> <span class='op'>=&gt;</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>latest</span><span class='tstring_end'>&quot;</span></span>
503
553
  <span class='rbrace'>}</span>
504
554
  <span class='kw'>end</span>
505
555
  <span class='kw'>return</span> <span class='id results'>results</span>
@@ -512,26 +562,62 @@
512
562
  <div class="method_details ">
513
563
  <p class="signature " id="real_name-instance_method">
514
564
 
515
- - (<tt>Object</tt>) <strong>real_name</strong>(owner)
565
+ - (<tt><span class='object_link'><a href="../../String.html" title="String (class)">String</a></span></tt>) <strong>real_name</strong>(owner)
516
566
 
517
567
 
518
568
 
519
- </p><table class="source_code">
569
+ </p><div class="docstring">
570
+ <div class="discussion">
571
+ <p>Use GitHub API v3 to look up the owner&rsquo;s real name</p>
572
+
573
+
574
+ </div>
575
+ </div>
576
+ <div class="tags">
577
+
578
+ <div class="examples">
579
+ <h3>Examples:</h3>
580
+
581
+ <h4><div class='inline'>
582
+ </div></h4>
583
+ <pre class="example code"><span class='id real_name'>real_name</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>saturnflyer</span><span class='tstring_end'>&quot;</span></span> <span class='comment'># =&gt; &quot;Jim Gay&quot;</span></pre>
584
+
585
+ </div>
586
+
587
+ <h3>Returns:</h3>
588
+ <ul class="return">
589
+
590
+ <li>
591
+
592
+
593
+ <span class='type'>(<tt><span class='object_link'><a href="../../String.html" title="String (class)">String</a></span></tt>)</span>
594
+
595
+
596
+
597
+ &mdash;
598
+ <div class='inline'><p>the owner&rsquo;s real name</p>
599
+ </div>
600
+
601
+ </li>
602
+
603
+ </ul>
604
+
605
+ </div><table class="source_code">
520
606
  <tr>
521
607
  <td>
522
608
  <pre class="lines">
523
609
 
524
610
 
525
- 33
526
- 34
527
- 35
528
- 36</pre>
611
+ 165
612
+ 166
613
+ 167
614
+ 168</pre>
529
615
  </td>
530
616
  <td>
531
- <pre class="code"><span class="info file"># File 'lib/ray/search/github.rb', line 33</span>
617
+ <pre class="code"><span class="info file"># File 'lib/ray/search.rb', line 165</span>
532
618
 
533
619
  <span class='kw'>def</span> <span class='id real_name'>real_name</span> <span class='id owner'>owner</span>
534
- <span class='id response'>response</span> <span class='op'>=</span> <span class='id open'>open</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span><span class='const'>GH_V3_API</span><span class='rbrace'>}</span><span class='tstring_content'>/users/</span><span class='embexpr_beg'>#{</span><span class='id owner'>owner</span><span class='rbrace'>}</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id read'>read</span>
620
+ <span class='id response'>response</span> <span class='op'>=</span> <span class='id open'>open</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>https://api.github.com/users/</span><span class='embexpr_beg'>#{</span><span class='id owner'>owner</span><span class='rbrace'>}</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id read'>read</span>
535
621
  <span class='const'>MultiJson</span><span class='period'>.</span><span class='id decode'>decode</span><span class='lparen'>(</span><span class='id response'>response</span><span class='rparen'>)</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>name</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span>
536
622
  <span class='kw'>end</span></pre>
537
623
  </td>
@@ -544,7 +630,7 @@
544
630
  </div>
545
631
 
546
632
  <div id="footer">
547
- Generated on Sun Nov 20 20:26:44 2011 by
633
+ Generated on Tue Nov 15 19:16:23 2011 by
548
634
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
549
635
  0.7.3 (ruby-1.9.3).
550
636
  </div>