rsteamshot 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/README.md +35 -10
- data/lib/rsteamshot.rb +14 -0
- data/lib/rsteamshot/app.rb +126 -40
- data/lib/rsteamshot/configuration.rb +7 -0
- data/lib/rsteamshot/screenshot.rb +51 -0
- data/lib/rsteamshot/user.rb +23 -6
- data/lib/rsteamshot/version.rb +1 -1
- data/rsteamshot.gemspec +5 -0
- metadata +7 -56
- data/docs/README_md.html +0 -233
- data/docs/Rsteamshot.html +0 -147
- data/docs/Rsteamshot/App.html +0 -466
- data/docs/Rsteamshot/App/BadAppsFile.html +0 -106
- data/docs/Rsteamshot/Screenshot.html +0 -562
- data/docs/Rsteamshot/ScreenshotPage.html +0 -347
- data/docs/Rsteamshot/ScreenshotPaginator.html +0 -307
- data/docs/Rsteamshot/User.html +0 -309
- data/docs/created.rid +0 -9
- data/docs/css/fonts.css +0 -167
- data/docs/css/rdoc.css +0 -590
- data/docs/fonts/Lato-Light.ttf +0 -0
- data/docs/fonts/Lato-LightItalic.ttf +0 -0
- data/docs/fonts/Lato-Regular.ttf +0 -0
- data/docs/fonts/Lato-RegularItalic.ttf +0 -0
- data/docs/fonts/SourceCodePro-Bold.ttf +0 -0
- data/docs/fonts/SourceCodePro-Regular.ttf +0 -0
- data/docs/images/add.png +0 -0
- data/docs/images/arrow_up.png +0 -0
- data/docs/images/brick.png +0 -0
- data/docs/images/brick_link.png +0 -0
- data/docs/images/bug.png +0 -0
- data/docs/images/bullet_black.png +0 -0
- data/docs/images/bullet_toggle_minus.png +0 -0
- data/docs/images/bullet_toggle_plus.png +0 -0
- data/docs/images/date.png +0 -0
- data/docs/images/delete.png +0 -0
- data/docs/images/find.png +0 -0
- data/docs/images/loadingAnimation.gif +0 -0
- data/docs/images/macFFBgHack.png +0 -0
- data/docs/images/package.png +0 -0
- data/docs/images/page_green.png +0 -0
- data/docs/images/page_white_text.png +0 -0
- data/docs/images/page_white_width.png +0 -0
- data/docs/images/plugin.png +0 -0
- data/docs/images/ruby.png +0 -0
- data/docs/images/tag_blue.png +0 -0
- data/docs/images/tag_green.png +0 -0
- data/docs/images/transparent.png +0 -0
- data/docs/images/wrench.png +0 -0
- data/docs/images/wrench_orange.png +0 -0
- data/docs/images/zoom.png +0 -0
- data/docs/index.html +0 -242
- data/docs/js/darkfish.js +0 -161
- data/docs/js/jquery.js +0 -4
- data/docs/js/navigation.js +0 -142
- data/docs/js/navigation.js.gz +0 -0
- data/docs/js/search.js +0 -109
- data/docs/js/search_index.js +0 -1
- data/docs/js/search_index.js.gz +0 -0
- data/docs/js/searcher.js +0 -229
- data/docs/js/searcher.js.gz +0 -0
- data/docs/table_of_contents.html +0 -179
data/lib/rsteamshot/user.rb
CHANGED
@@ -11,6 +11,9 @@ module Rsteamshot
|
|
11
11
|
# Public: Returns a String user name from a Steam user's public profile.
|
12
12
|
attr_reader :user_name
|
13
13
|
|
14
|
+
# Public: Returns the number of screenshots that will be fetched per page for this user.
|
15
|
+
attr_reader :per_page
|
16
|
+
|
14
17
|
# Public: Initialize a Steam user with the given user name.
|
15
18
|
#
|
16
19
|
# user_name - a String
|
@@ -18,12 +21,8 @@ module Rsteamshot
|
|
18
21
|
# Integer
|
19
22
|
def initialize(user_name, per_page: 10)
|
20
23
|
@user_name = user_name
|
21
|
-
|
22
|
-
|
23
|
-
links_from(html).map { |link| screenshot_from(link) }
|
24
|
-
end
|
25
|
-
@paginator = ScreenshotPaginator.new(process_html, max_per_page: STEAM_PER_PAGE,
|
26
|
-
per_page: per_page, steam_per_page: STEAM_PER_PAGE)
|
24
|
+
@per_page = per_page
|
25
|
+
initialize_paginator
|
27
26
|
end
|
28
27
|
|
29
28
|
# Public: Fetch a list of the user's newest uploaded screenshots.
|
@@ -42,8 +41,26 @@ module Rsteamshot
|
|
42
41
|
@paginator.screenshots(page: page, url: url)
|
43
42
|
end
|
44
43
|
|
44
|
+
# Public: Set how many screenshots should be fetched at a time for this user.
|
45
|
+
#
|
46
|
+
# value - an Integer
|
47
|
+
#
|
48
|
+
# Returns nothing.
|
49
|
+
def per_page=(value)
|
50
|
+
@per_page = value
|
51
|
+
initialize_paginator
|
52
|
+
end
|
53
|
+
|
45
54
|
private
|
46
55
|
|
56
|
+
def initialize_paginator
|
57
|
+
process_html = ->(html) do
|
58
|
+
links_from(html).map { |link| screenshot_from(link) }
|
59
|
+
end
|
60
|
+
@paginator = ScreenshotPaginator.new(process_html, max_per_page: STEAM_PER_PAGE,
|
61
|
+
per_page: per_page, steam_per_page: STEAM_PER_PAGE)
|
62
|
+
end
|
63
|
+
|
47
64
|
def links_from(html)
|
48
65
|
html.search('#image_wall .imageWallRow .profile_media_item')
|
49
66
|
end
|
data/lib/rsteamshot/version.rb
CHANGED
data/rsteamshot.gemspec
CHANGED
@@ -8,6 +8,11 @@ Gem::Specification.new do |spec|
|
|
8
8
|
spec.version = Rsteamshot::VERSION
|
9
9
|
spec.authors = ['Sarah Vessels']
|
10
10
|
spec.email = ['cheshire137@gmail.com']
|
11
|
+
spec.metadata = {
|
12
|
+
'changelog_uri' => 'https://github.com/cheshire137/rsteamshot/blob/master/CHANGELOG.md',
|
13
|
+
'documentation_uri' => 'http://www.rubydoc.info/gems/rsteamshot/',
|
14
|
+
'source_code_uri' => 'https://github.com/cheshire137/rsteamshot'
|
15
|
+
}
|
11
16
|
|
12
17
|
spec.summary = %q{Get Steam screenshots for different games or users.}
|
13
18
|
spec.description = %q{Find screenshots publicly uploaded to Steam by a particular user or for a particular game. Get details like the title, how many likes and comments it has received, the dimensions and file size, and URLs for different sizes of each screenshot.}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rsteamshot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sarah Vessels
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-11-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -128,61 +128,9 @@ files:
|
|
128
128
|
- Rakefile
|
129
129
|
- bin/console
|
130
130
|
- bin/setup
|
131
|
-
- docs/README_md.html
|
132
|
-
- docs/Rsteamshot.html
|
133
|
-
- docs/Rsteamshot/App.html
|
134
|
-
- docs/Rsteamshot/App/BadAppsFile.html
|
135
|
-
- docs/Rsteamshot/Screenshot.html
|
136
|
-
- docs/Rsteamshot/ScreenshotPage.html
|
137
|
-
- docs/Rsteamshot/ScreenshotPaginator.html
|
138
|
-
- docs/Rsteamshot/User.html
|
139
|
-
- docs/created.rid
|
140
|
-
- docs/css/fonts.css
|
141
|
-
- docs/css/rdoc.css
|
142
|
-
- docs/fonts/Lato-Light.ttf
|
143
|
-
- docs/fonts/Lato-LightItalic.ttf
|
144
|
-
- docs/fonts/Lato-Regular.ttf
|
145
|
-
- docs/fonts/Lato-RegularItalic.ttf
|
146
|
-
- docs/fonts/SourceCodePro-Bold.ttf
|
147
|
-
- docs/fonts/SourceCodePro-Regular.ttf
|
148
|
-
- docs/images/add.png
|
149
|
-
- docs/images/arrow_up.png
|
150
|
-
- docs/images/brick.png
|
151
|
-
- docs/images/brick_link.png
|
152
|
-
- docs/images/bug.png
|
153
|
-
- docs/images/bullet_black.png
|
154
|
-
- docs/images/bullet_toggle_minus.png
|
155
|
-
- docs/images/bullet_toggle_plus.png
|
156
|
-
- docs/images/date.png
|
157
|
-
- docs/images/delete.png
|
158
|
-
- docs/images/find.png
|
159
|
-
- docs/images/loadingAnimation.gif
|
160
|
-
- docs/images/macFFBgHack.png
|
161
|
-
- docs/images/package.png
|
162
|
-
- docs/images/page_green.png
|
163
|
-
- docs/images/page_white_text.png
|
164
|
-
- docs/images/page_white_width.png
|
165
|
-
- docs/images/plugin.png
|
166
|
-
- docs/images/ruby.png
|
167
|
-
- docs/images/tag_blue.png
|
168
|
-
- docs/images/tag_green.png
|
169
|
-
- docs/images/transparent.png
|
170
|
-
- docs/images/wrench.png
|
171
|
-
- docs/images/wrench_orange.png
|
172
|
-
- docs/images/zoom.png
|
173
|
-
- docs/index.html
|
174
|
-
- docs/js/darkfish.js
|
175
|
-
- docs/js/jquery.js
|
176
|
-
- docs/js/navigation.js
|
177
|
-
- docs/js/navigation.js.gz
|
178
|
-
- docs/js/search.js
|
179
|
-
- docs/js/search_index.js
|
180
|
-
- docs/js/search_index.js.gz
|
181
|
-
- docs/js/searcher.js
|
182
|
-
- docs/js/searcher.js.gz
|
183
|
-
- docs/table_of_contents.html
|
184
131
|
- lib/rsteamshot.rb
|
185
132
|
- lib/rsteamshot/app.rb
|
133
|
+
- lib/rsteamshot/configuration.rb
|
186
134
|
- lib/rsteamshot/screenshot.rb
|
187
135
|
- lib/rsteamshot/screenshot_page.rb
|
188
136
|
- lib/rsteamshot/screenshot_paginator.rb
|
@@ -192,7 +140,10 @@ files:
|
|
192
140
|
homepage: https://github.com/cheshire137/rsteamshot
|
193
141
|
licenses:
|
194
142
|
- MIT
|
195
|
-
metadata:
|
143
|
+
metadata:
|
144
|
+
changelog_uri: https://github.com/cheshire137/rsteamshot/blob/master/CHANGELOG.md
|
145
|
+
documentation_uri: http://www.rubydoc.info/gems/rsteamshot/
|
146
|
+
source_code_uri: https://github.com/cheshire137/rsteamshot
|
196
147
|
post_install_message:
|
197
148
|
rdoc_options: []
|
198
149
|
require_paths:
|
data/docs/README_md.html
DELETED
@@ -1,233 +0,0 @@
|
|
1
|
-
<!DOCTYPE html>
|
2
|
-
|
3
|
-
<html>
|
4
|
-
<head>
|
5
|
-
<meta charset="UTF-8">
|
6
|
-
|
7
|
-
<title>README - RDoc Documentation</title>
|
8
|
-
|
9
|
-
<script type="text/javascript">
|
10
|
-
var rdoc_rel_prefix = "./";
|
11
|
-
var index_rel_prefix = "./";
|
12
|
-
</script>
|
13
|
-
|
14
|
-
<script src="./js/jquery.js"></script>
|
15
|
-
<script src="./js/darkfish.js"></script>
|
16
|
-
|
17
|
-
<link href="./css/fonts.css" rel="stylesheet">
|
18
|
-
<link href="./css/rdoc.css" rel="stylesheet">
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
<body id="top" role="document" class="file">
|
23
|
-
<nav role="navigation">
|
24
|
-
<div id="project-navigation">
|
25
|
-
<div id="home-section" role="region" title="Quick navigation" class="nav-section">
|
26
|
-
<h2>
|
27
|
-
<a href="./index.html" rel="home">Home</a>
|
28
|
-
</h2>
|
29
|
-
|
30
|
-
<div id="table-of-contents-navigation">
|
31
|
-
<a href="./table_of_contents.html#pages">Pages</a>
|
32
|
-
<a href="./table_of_contents.html#classes">Classes</a>
|
33
|
-
<a href="./table_of_contents.html#methods">Methods</a>
|
34
|
-
</div>
|
35
|
-
</div>
|
36
|
-
|
37
|
-
<div id="search-section" role="search" class="project-section initially-hidden">
|
38
|
-
<form action="#" method="get" accept-charset="utf-8">
|
39
|
-
<div id="search-field-wrapper">
|
40
|
-
<input id="search-field" role="combobox" aria-label="Search"
|
41
|
-
aria-autocomplete="list" aria-controls="search-results"
|
42
|
-
type="text" name="search" placeholder="Search" spellcheck="false"
|
43
|
-
title="Type to search, Up and Down to navigate, Enter to load">
|
44
|
-
</div>
|
45
|
-
|
46
|
-
<ul id="search-results" aria-label="Search Results"
|
47
|
-
aria-busy="false" aria-expanded="false"
|
48
|
-
aria-atomic="false" class="initially-hidden"></ul>
|
49
|
-
</form>
|
50
|
-
</div>
|
51
|
-
|
52
|
-
</div>
|
53
|
-
|
54
|
-
|
55
|
-
<div class="nav-section">
|
56
|
-
<h3>Table of Contents</h3>
|
57
|
-
|
58
|
-
<ul class="link-list" role="directory">
|
59
|
-
<li><a href="#label-Rsteamshot">Rsteamshot</a>
|
60
|
-
<li><a href="#label-Installation">Installation</a>
|
61
|
-
<li><a href="#label-Usage">Usage</a>
|
62
|
-
<li><a href="#label-Development">Development</a>
|
63
|
-
<li><a href="#label-Contributing">Contributing</a>
|
64
|
-
<li><a href="#label-License">License</a>
|
65
|
-
</ul>
|
66
|
-
</div>
|
67
|
-
|
68
|
-
|
69
|
-
<div id="project-metadata">
|
70
|
-
<div id="fileindex-section" class="nav-section">
|
71
|
-
<h3>Pages</h3>
|
72
|
-
|
73
|
-
<ul class="link-list">
|
74
|
-
|
75
|
-
<li><a href="./README_md.html">README</a>
|
76
|
-
|
77
|
-
</ul>
|
78
|
-
</div>
|
79
|
-
|
80
|
-
</div>
|
81
|
-
</nav>
|
82
|
-
|
83
|
-
<main role="main" aria-label="Page README.md">
|
84
|
-
|
85
|
-
<h1 id="label-Rsteamshot"><a href="Rsteamshot.html">Rsteamshot</a><span><a href="#label-Rsteamshot">¶</a> <a href="#top">↑</a></span></h1>
|
86
|
-
|
87
|
-
<p><a href="https://travis-ci.org/cheshire137/rsteamshot"><img
|
88
|
-
src="https://travis-ci.org/cheshire137/rsteamshot.svg?branch=master"></a></p>
|
89
|
-
|
90
|
-
<p><a href="Rsteamshot.html">Rsteamshot</a> is a Ruby gem for getting
|
91
|
-
screenshots a user has uploaded to their Steam profile, as well as
|
92
|
-
screenshots uploaded for a particular game. You can find the newest
|
93
|
-
screenshots as well as the most popular screenshots. Screenshots can be
|
94
|
-
paginated.</p>
|
95
|
-
|
96
|
-
<p>There's no Steam API that I know of that provides this screenshot data,
|
97
|
-
so this gem works by using <a
|
98
|
-
href="https://github.com/sparklemotion/mechanize">Mechanize</a> to do web
|
99
|
-
scraping on <a href="http://steamcommunity.com/">steamcommunity.com</a>.</p>
|
100
|
-
|
101
|
-
<p><a href="https://github.com/cheshire137/rsteamshot">View source on
|
102
|
-
GitHub</a></p>
|
103
|
-
|
104
|
-
<h2 id="label-Installation">Installation<span><a href="#label-Installation">¶</a> <a href="#top">↑</a></span></h2>
|
105
|
-
|
106
|
-
<p>Add this line to your application's Gemfile:</p>
|
107
|
-
|
108
|
-
<pre class="ruby"><span class="ruby-identifier">gem</span> <span class="ruby-string">'rsteamshot'</span>
|
109
|
-
</pre>
|
110
|
-
|
111
|
-
<p>And then execute:</p>
|
112
|
-
|
113
|
-
<pre>$ bundle</pre>
|
114
|
-
|
115
|
-
<p>Or install it yourself as:</p>
|
116
|
-
|
117
|
-
<pre>$ gem install rsteamshot</pre>
|
118
|
-
|
119
|
-
<h2 id="label-Usage">Usage<span><a href="#label-Usage">¶</a> <a href="#top">↑</a></span></h2>
|
120
|
-
|
121
|
-
<pre class="ruby"><span class="ruby-comment"># Get screenshots uploaded by a Steam user:</span>
|
122
|
-
<span class="ruby-identifier">steam_user_name</span> = <span class="ruby-string">'cheshire137'</span>
|
123
|
-
<span class="ruby-identifier">user</span> = <span class="ruby-constant">Rsteamshot</span><span class="ruby-operator">::</span><span class="ruby-constant">User</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">steam_user_name</span>, <span class="ruby-identifier">per_page</span><span class="ruby-operator">:</span> <span class="ruby-value">10</span>)
|
124
|
-
<span class="ruby-identifier">order</span> = <span class="ruby-string">'newestfirst'</span> <span class="ruby-comment"># also: score, oldestfirst</span>
|
125
|
-
<span class="ruby-identifier">screenshots</span> = <span class="ruby-identifier">user</span>.<span class="ruby-identifier">screenshots</span>(<span class="ruby-identifier">order</span><span class="ruby-operator">:</span> <span class="ruby-identifier">order</span>)
|
126
|
-
<span class="ruby-identifier">screenshots</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">user</span>.<span class="ruby-identifier">screenshots</span>(<span class="ruby-identifier">order</span><span class="ruby-operator">:</span> <span class="ruby-identifier">order</span>, <span class="ruby-identifier">page</span><span class="ruby-operator">:</span> <span class="ruby-value">2</span>)
|
127
|
-
|
128
|
-
<span class="ruby-comment"># Find a Steam app by name:</span>
|
129
|
-
<span class="ruby-identifier">apps_path</span> = <span class="ruby-string">'apps-list.json'</span>
|
130
|
-
<span class="ruby-constant">Rsteamshot</span><span class="ruby-operator">::</span><span class="ruby-constant">App</span>.<span class="ruby-identifier">download_apps_list</span>(<span class="ruby-identifier">apps_path</span>)
|
131
|
-
<span class="ruby-identifier">apps</span> = <span class="ruby-constant">Rsteamshot</span><span class="ruby-operator">::</span><span class="ruby-constant">App</span>.<span class="ruby-identifier">search</span>(<span class="ruby-string">'witcher 3'</span>, <span class="ruby-identifier">apps_path</span>)
|
132
|
-
<span class="ruby-identifier">app</span> = <span class="ruby-identifier">apps</span>.<span class="ruby-identifier">first</span>
|
133
|
-
|
134
|
-
<span class="ruby-comment"># Filter a user's screenshots to those for a particular app:</span>
|
135
|
-
<span class="ruby-identifier">alice_screenshots</span> = <span class="ruby-identifier">user</span>.<span class="ruby-identifier">screenshots</span>(<span class="ruby-identifier">app_id</span><span class="ruby-operator">:</span> <span class="ruby-string">'19680'</span>)
|
136
|
-
|
137
|
-
<span class="ruby-comment"># Initialize an app directly if you know its ID:</span>
|
138
|
-
<span class="ruby-identifier">app_id</span> = <span class="ruby-string">'377160'</span>
|
139
|
-
<span class="ruby-identifier">app</span> = <span class="ruby-constant">Rsteamshot</span><span class="ruby-operator">::</span><span class="ruby-constant">App</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">id</span><span class="ruby-operator">:</span> <span class="ruby-identifier">app_id</span>, <span class="ruby-identifier">per_page</span><span class="ruby-operator">:</span> <span class="ruby-value">10</span>)
|
140
|
-
|
141
|
-
<span class="ruby-comment"># Get screenshots uploaded for a Steam game:</span>
|
142
|
-
<span class="ruby-identifier">order</span> = <span class="ruby-string">'mostrecent'</span> <span class="ruby-comment"># also: toprated, trendday, trendweek, trendthreemonths, trendsixmonths,</span>
|
143
|
-
<span class="ruby-comment"># trendyear</span>
|
144
|
-
<span class="ruby-identifier">screenshots</span> = <span class="ruby-identifier">app</span>.<span class="ruby-identifier">screenshots</span>(<span class="ruby-identifier">order</span><span class="ruby-operator">:</span> <span class="ruby-identifier">order</span>)
|
145
|
-
<span class="ruby-identifier">screenshots</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">app</span>.<span class="ruby-identifier">screenshots</span>(<span class="ruby-identifier">order</span><span class="ruby-operator">:</span> <span class="ruby-identifier">order</span>, <span class="ruby-identifier">page</span><span class="ruby-operator">:</span> <span class="ruby-value">2</span>)
|
146
|
-
|
147
|
-
<span class="ruby-comment"># Search an app's screenshots:</span>
|
148
|
-
<span class="ruby-identifier">dog_screenshots</span> = <span class="ruby-identifier">app</span>.<span class="ruby-identifier">screenshots</span>(<span class="ruby-identifier">query</span><span class="ruby-operator">:</span> <span class="ruby-string">'dog'</span>, <span class="ruby-identifier">order</span><span class="ruby-operator">:</span> <span class="ruby-string">'trendweek'</span>)
|
149
|
-
|
150
|
-
<span class="ruby-comment"># Data available for each screenshot:</span>
|
151
|
-
<span class="ruby-identifier">screenshots</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">screenshot</span><span class="ruby-operator">|</span>
|
152
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">title</span>
|
153
|
-
<span class="ruby-comment"># => "Lovely sunset in Toussaint"</span>
|
154
|
-
|
155
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">details_url</span>
|
156
|
-
<span class="ruby-comment"># => "http://steamcommunity.com/sharedfiles/filedetails/?id=737284878"</span>
|
157
|
-
|
158
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">full_size_url</span>
|
159
|
-
<span class="ruby-comment"># => "https://steamuserimages-a.akamaihd.net/ugc/1621679306978373648/FACBF0285AFB413467E0E76371E8796D8E8C263D/"</span>
|
160
|
-
|
161
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">medium_url</span>
|
162
|
-
<span class="ruby-comment"># => "https://steamuserimages-a.akamaihd.net/ugc/1621679306978373648/FACBF0285AFB413467E0E76371E8796D8E8C263D/?interpolation=lanczos-none&output-format=jpeg&output-quality=95&fit=inside|1024:576&composite-to%3D%2A%2C%2A%7C1024%3A576&background-color=black"</span>
|
163
|
-
|
164
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">user_name</span>
|
165
|
-
<span class="ruby-comment"># => "cheshire137"</span>
|
166
|
-
|
167
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">user_url</span>
|
168
|
-
<span class="ruby-comment"># => "http://steamcommunity.com/id/cheshire137"</span>
|
169
|
-
|
170
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">date</span>
|
171
|
-
<span class="ruby-comment"># => #<DateTime: 2016-08-03T20:54:00+00:00 ((2457604j,75240s,0n),+0s,2299161j)></span>
|
172
|
-
|
173
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">file_size</span>
|
174
|
-
<span class="ruby-comment"># => "0.367 MB"</span>
|
175
|
-
|
176
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">width</span>
|
177
|
-
<span class="ruby-comment"># => 1920</span>
|
178
|
-
|
179
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">height</span>
|
180
|
-
<span class="ruby-comment"># => 1080</span>
|
181
|
-
|
182
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">like_count</span>
|
183
|
-
<span class="ruby-comment"># => 0</span>
|
184
|
-
|
185
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">comment_count</span>
|
186
|
-
<span class="ruby-comment"># => 0</span>
|
187
|
-
|
188
|
-
<span class="ruby-comment"># Utility methods:</span>
|
189
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">to_h</span>
|
190
|
-
<span class="ruby-comment"># => {:details_url=>"http://steamcommunity.com/sharedfiles/filedetails/?id=737284878", :title=>...</span>
|
191
|
-
|
192
|
-
<span class="ruby-identifier">screenshot</span>.<span class="ruby-identifier">to_json</span>
|
193
|
-
<span class="ruby-comment"># => "{\n \"details_url\": \"http://steamcommunity.com/sharedfiles/filedetails/?id=737284878\",</span>
|
194
|
-
<span class="ruby-keyword">end</span>
|
195
|
-
</pre>
|
196
|
-
|
197
|
-
<h2 id="label-Development">Development<span><a href="#label-Development">¶</a> <a href="#top">↑</a></span></h2>
|
198
|
-
|
199
|
-
<p>After checking out <a href="https://github.com/cheshire137/rsteamshot">the
|
200
|
-
repo</a>, run <code>bin/setup</code> to install dependencies. Then, run
|
201
|
-
<code>rake spec</code> to run the tests. You can also run
|
202
|
-
<code>bin/console</code> for an interactive prompt that will allow you to
|
203
|
-
experiment.</p>
|
204
|
-
|
205
|
-
<p>To install this gem onto your local machine, run <code>bundle exec rake
|
206
|
-
install</code>. To release a new version, update the version number in
|
207
|
-
<code>version.rb</code>, and then run <code>bundle exec rake
|
208
|
-
release</code>, which will create a git tag for the version, push git
|
209
|
-
commits and tags, and push the <code>.gem</code> file to <a
|
210
|
-
href="https://rubygems.org">rubygems.org</a>.</p>
|
211
|
-
|
212
|
-
<h2 id="label-Contributing">Contributing<span><a href="#label-Contributing">¶</a> <a href="#top">↑</a></span></h2>
|
213
|
-
|
214
|
-
<p><a href="https://github.com/cheshire137/rsteamshot/issues">Bug reports</a>
|
215
|
-
and pull requests are welcome. This project is intended to be a safe,
|
216
|
-
welcoming space for collaboration, and contributors are expected to adhere
|
217
|
-
to the <a href="http://contributor-covenant.org">Contributor Covenant</a>
|
218
|
-
code of conduct.</p>
|
219
|
-
|
220
|
-
<h2 id="label-License">License<span><a href="#label-License">¶</a> <a href="#top">↑</a></span></h2>
|
221
|
-
|
222
|
-
<p>The gem is available as open source under the terms of the <a
|
223
|
-
href="http://opensource.org/licenses/MIT">MIT License</a>.</p>
|
224
|
-
</main>
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
<footer id="validator-badges" role="contentinfo">
|
229
|
-
<p><a href="http://validator.w3.org/check/referer">Validate</a>
|
230
|
-
<p>Generated by <a href="https://rdoc.github.io/rdoc">RDoc</a> 5.1.0.
|
231
|
-
<p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
|
232
|
-
</footer>
|
233
|
-
|
data/docs/Rsteamshot.html
DELETED
@@ -1,147 +0,0 @@
|
|
1
|
-
<!DOCTYPE html>
|
2
|
-
|
3
|
-
<html>
|
4
|
-
<head>
|
5
|
-
<meta charset="UTF-8">
|
6
|
-
|
7
|
-
<title>module Rsteamshot - RDoc Documentation</title>
|
8
|
-
|
9
|
-
<script type="text/javascript">
|
10
|
-
var rdoc_rel_prefix = "./";
|
11
|
-
var index_rel_prefix = "./";
|
12
|
-
</script>
|
13
|
-
|
14
|
-
<script src="./js/jquery.js"></script>
|
15
|
-
<script src="./js/darkfish.js"></script>
|
16
|
-
|
17
|
-
<link href="./css/fonts.css" rel="stylesheet">
|
18
|
-
<link href="./css/rdoc.css" rel="stylesheet">
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
<body id="top" role="document" class="module">
|
23
|
-
<nav role="navigation">
|
24
|
-
<div id="project-navigation">
|
25
|
-
<div id="home-section" role="region" title="Quick navigation" class="nav-section">
|
26
|
-
<h2>
|
27
|
-
<a href="./index.html" rel="home">Home</a>
|
28
|
-
</h2>
|
29
|
-
|
30
|
-
<div id="table-of-contents-navigation">
|
31
|
-
<a href="./table_of_contents.html#pages">Pages</a>
|
32
|
-
<a href="./table_of_contents.html#classes">Classes</a>
|
33
|
-
<a href="./table_of_contents.html#methods">Methods</a>
|
34
|
-
</div>
|
35
|
-
</div>
|
36
|
-
|
37
|
-
<div id="search-section" role="search" class="project-section initially-hidden">
|
38
|
-
<form action="#" method="get" accept-charset="utf-8">
|
39
|
-
<div id="search-field-wrapper">
|
40
|
-
<input id="search-field" role="combobox" aria-label="Search"
|
41
|
-
aria-autocomplete="list" aria-controls="search-results"
|
42
|
-
type="text" name="search" placeholder="Search" spellcheck="false"
|
43
|
-
title="Type to search, Up and Down to navigate, Enter to load">
|
44
|
-
</div>
|
45
|
-
|
46
|
-
<ul id="search-results" aria-label="Search Results"
|
47
|
-
aria-busy="false" aria-expanded="false"
|
48
|
-
aria-atomic="false" class="initially-hidden"></ul>
|
49
|
-
</form>
|
50
|
-
</div>
|
51
|
-
|
52
|
-
</div>
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
<div id="class-metadata">
|
57
|
-
<div id="sections-section" class="nav-section">
|
58
|
-
<h3>Sections</h3>
|
59
|
-
|
60
|
-
<ul class="link-list" role="directory">
|
61
|
-
|
62
|
-
<li><a href="#5Buntitled-5D"></a></li>
|
63
|
-
|
64
|
-
<li><a href="#Public">Public</a></li>
|
65
|
-
|
66
|
-
</ul>
|
67
|
-
</div>
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
</div>
|
74
|
-
</nav>
|
75
|
-
|
76
|
-
<main role="main" aria-labelledby="module-Rsteamshot">
|
77
|
-
<h1 id="module-Rsteamshot" class="module">
|
78
|
-
module Rsteamshot
|
79
|
-
</h1>
|
80
|
-
|
81
|
-
<section class="description">
|
82
|
-
|
83
|
-
<p>Contains classes for finding screenshots uploaded by users to Steam.
|
84
|
-
Screenshots are from Steam games (apps).</p>
|
85
|
-
|
86
|
-
</section>
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
<section id="5Buntitled-5D" class="documentation-section">
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
</section>
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
<section id="Public" class="documentation-section">
|
106
|
-
|
107
|
-
<header class="documentation-section-title">
|
108
|
-
<h2>
|
109
|
-
Public
|
110
|
-
</h2>
|
111
|
-
<span class="section-click-top">
|
112
|
-
<a href="#top">↑ top</a>
|
113
|
-
</span>
|
114
|
-
</header>
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
<section class="constants-list">
|
121
|
-
<header>
|
122
|
-
<h3>Constants</h3>
|
123
|
-
</header>
|
124
|
-
<dl>
|
125
|
-
|
126
|
-
<dt id="VERSION">VERSION
|
127
|
-
|
128
|
-
<dd><p>The current version of the <a href="Rsteamshot.html">Rsteamshot</a> gem.</p>
|
129
|
-
|
130
|
-
|
131
|
-
</dl>
|
132
|
-
</section>
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
</section>
|
139
|
-
</main>
|
140
|
-
|
141
|
-
|
142
|
-
<footer id="validator-badges" role="contentinfo">
|
143
|
-
<p><a href="http://validator.w3.org/check/referer">Validate</a>
|
144
|
-
<p>Generated by <a href="https://rdoc.github.io/rdoc">RDoc</a> 5.1.0.
|
145
|
-
<p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
|
146
|
-
</footer>
|
147
|
-
|