device_wizard 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.idea/.name +1 -0
- data/.idea/.rakeTasks +7 -0
- data/.idea/device_wizard.iml +29 -0
- data/.idea/encodings.xml +6 -0
- data/.idea/misc.xml +14 -0
- data/.idea/modules.xml +8 -0
- data/.idea/vcs.xml +6 -0
- data/.idea/workspace.xml +708 -0
- data/README.md +24 -4
- data/lib/device_wizard.rb +341 -0
- data/lib/device_wizard/version.rb +1 -1
- metadata +10 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 406bf43f4fe4c815ffd03e19efc2caa55eeedb2e
|
4
|
+
data.tar.gz: d7ab087236486dff9d14d43b75e097f5bed77ac4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 60252f7a27a3bbcc1458416e6ccbf30e0b7c7053cda0ec1c7a06198cd1d25fc9fdabed51d18b6a83753f8013aff2f6b2147e10e8b6200dd29d0562d2056e765e
|
7
|
+
data.tar.gz: c8b39d1520ba064d8c437982ddb82d09acea6e95e7d1a83c1fc805726d23ea8124bf49ef0442ba68f98295e6e5abe2c102ac7ca04a74dc91c883fa9176c29ad0
|
data/.idea/.name
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
device_wizard
|
data/.idea/.rakeTasks
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<Settings><!--This file was automatically generated by Ruby plugin.
|
3
|
+
You are allowed to:
|
4
|
+
1. Remove rake task
|
5
|
+
2. Add existing rake tasks
|
6
|
+
To add existing rake tasks automatically delete this file and reload the project.
|
7
|
+
--><RakeGroup description="" fullCmd="" taksId="rake"><RakeTask description="Build device_wizard-0.1.0.gem into the pkg directory" fullCmd="build" taksId="build" /><RakeTask description="Remove any temporary products" fullCmd="clean" taksId="clean" /><RakeTask description="Remove any generated files" fullCmd="clobber" taksId="clobber" /><RakeTask description="Build and install device_wizard-0.1.0.gem into system gems" fullCmd="install" taksId="install" /><RakeGroup description="" fullCmd="" taksId="install"><RakeTask description="Build and install device_wizard-0.1.0.gem into system gems without network access" fullCmd="install:local" taksId="local" /></RakeGroup><RakeTask description="Create tag v0.1.0 and build and push device_wizard-0.1.0.gem to Rubygems" fullCmd="release[remote]" taksId="release[remote]" /><RakeTask description="" fullCmd="default" taksId="default" /><RakeTask description="" fullCmd="release" taksId="release" /><RakeGroup description="" fullCmd="" taksId="release"><RakeTask description="" fullCmd="release:guard_clean" taksId="guard_clean" /><RakeTask description="" fullCmd="release:rubygem_push" taksId="rubygem_push" /><RakeTask description="" fullCmd="release:source_control_push" taksId="source_control_push" /></RakeGroup></RakeGroup></Settings>
|
@@ -0,0 +1,29 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<module type="RUBY_MODULE" version="4">
|
3
|
+
<component name="FacetManager">
|
4
|
+
<facet type="gem" name="Ruby Gem">
|
5
|
+
<configuration>
|
6
|
+
<option name="GEM_APP_ROOT_PATH" value="$MODULE_DIR$" />
|
7
|
+
<option name="GEM_APP_TEST_PATH" value="" />
|
8
|
+
<option name="GEM_APP_LIB_PATH" value="$MODULE_DIR$/lib" />
|
9
|
+
</configuration>
|
10
|
+
</facet>
|
11
|
+
</component>
|
12
|
+
<component name="NewModuleRootManager">
|
13
|
+
<content url="file://$MODULE_DIR$" />
|
14
|
+
<orderEntry type="inheritedJdk" />
|
15
|
+
<orderEntry type="sourceFolder" forTests="false" />
|
16
|
+
<orderEntry type="library" scope="PROVIDED" name="bundler (v1.11.2, rbenv: 2.1.5) [gem]" level="application" />
|
17
|
+
<orderEntry type="library" scope="PROVIDED" name="coderay (v1.1.0, rbenv: 2.1.5) [gem]" level="application" />
|
18
|
+
<orderEntry type="library" scope="PROVIDED" name="diff-lcs (v1.2.5, rbenv: 2.1.5) [gem]" level="application" />
|
19
|
+
<orderEntry type="library" scope="PROVIDED" name="method_source (v0.8.2, rbenv: 2.1.5) [gem]" level="application" />
|
20
|
+
<orderEntry type="library" scope="PROVIDED" name="pry (v0.10.3, rbenv: 2.1.5) [gem]" level="application" />
|
21
|
+
<orderEntry type="library" scope="PROVIDED" name="rake (v10.5.0, rbenv: 2.1.5) [gem]" level="application" />
|
22
|
+
<orderEntry type="library" scope="PROVIDED" name="rspec (v3.4.0, rbenv: 2.1.5) [gem]" level="application" />
|
23
|
+
<orderEntry type="library" scope="PROVIDED" name="rspec-core (v3.4.2, rbenv: 2.1.5) [gem]" level="application" />
|
24
|
+
<orderEntry type="library" scope="PROVIDED" name="rspec-expectations (v3.4.0, rbenv: 2.1.5) [gem]" level="application" />
|
25
|
+
<orderEntry type="library" scope="PROVIDED" name="rspec-mocks (v3.4.1, rbenv: 2.1.5) [gem]" level="application" />
|
26
|
+
<orderEntry type="library" scope="PROVIDED" name="rspec-support (v3.4.1, rbenv: 2.1.5) [gem]" level="application" />
|
27
|
+
<orderEntry type="library" scope="PROVIDED" name="slop (v3.6.0, rbenv: 2.1.5) [gem]" level="application" />
|
28
|
+
</component>
|
29
|
+
</module>
|
data/.idea/encodings.xml
ADDED
data/.idea/misc.xml
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<project version="4">
|
3
|
+
<component name="ProjectLevelVcsManager" settingsEditedManually="false">
|
4
|
+
<OptionsSetting value="true" id="Add" />
|
5
|
+
<OptionsSetting value="true" id="Remove" />
|
6
|
+
<OptionsSetting value="true" id="Checkout" />
|
7
|
+
<OptionsSetting value="true" id="Update" />
|
8
|
+
<OptionsSetting value="true" id="Status" />
|
9
|
+
<OptionsSetting value="true" id="Edit" />
|
10
|
+
<ConfirmationsSetting value="0" id="Add" />
|
11
|
+
<ConfirmationsSetting value="0" id="Remove" />
|
12
|
+
</component>
|
13
|
+
<component name="ProjectRootManager" version="2" project-jdk-name="rbenv: 2.1.5" project-jdk-type="RUBY_SDK" />
|
14
|
+
</project>
|
data/.idea/modules.xml
ADDED
@@ -0,0 +1,8 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<project version="4">
|
3
|
+
<component name="ProjectModuleManager">
|
4
|
+
<modules>
|
5
|
+
<module fileurl="file://$PROJECT_DIR$/.idea/device_wizard.iml" filepath="$PROJECT_DIR$/.idea/device_wizard.iml" />
|
6
|
+
</modules>
|
7
|
+
</component>
|
8
|
+
</project>
|
data/.idea/vcs.xml
ADDED
data/.idea/workspace.xml
ADDED
@@ -0,0 +1,708 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<project version="4">
|
3
|
+
<component name="ChangeListManager">
|
4
|
+
<list default="true" id="d61b7375-c87d-4649-8619-301d696e3e1d" name="Default" comment="" />
|
5
|
+
<ignored path="device_wizard.iws" />
|
6
|
+
<ignored path=".idea/workspace.xml" />
|
7
|
+
<ignored path=".idea/dataSources.local.xml" />
|
8
|
+
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
9
|
+
<option name="TRACKING_ENABLED" value="true" />
|
10
|
+
<option name="SHOW_DIALOG" value="false" />
|
11
|
+
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
12
|
+
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
13
|
+
<option name="LAST_RESOLUTION" value="IGNORE" />
|
14
|
+
</component>
|
15
|
+
<component name="ChangesViewManager" flattened_view="true" show_ignored="false" />
|
16
|
+
<component name="CreatePatchCommitExecutor">
|
17
|
+
<option name="PATCH_PATH" value="" />
|
18
|
+
</component>
|
19
|
+
<component name="FavoritesManager">
|
20
|
+
<favorites_list name="device_wizard" />
|
21
|
+
</component>
|
22
|
+
<component name="FileEditorManager">
|
23
|
+
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
|
24
|
+
<file leaf-file-name="device_wizard.gemspec" pinned="false" current-in-tab="false">
|
25
|
+
<entry file="file://$PROJECT_DIR$/device_wizard.gemspec">
|
26
|
+
<provider selected="true" editor-type-id="text-editor">
|
27
|
+
<state vertical-scroll-proportion="0.0">
|
28
|
+
<caret line="19" column="30" selection-start-line="19" selection-start-column="30" selection-end-line="19" selection-end-column="30" />
|
29
|
+
<folding />
|
30
|
+
</state>
|
31
|
+
</provider>
|
32
|
+
</entry>
|
33
|
+
</file>
|
34
|
+
<file leaf-file-name="version.rb" pinned="false" current-in-tab="false">
|
35
|
+
<entry file="file://$PROJECT_DIR$/lib/device_wizard/version.rb">
|
36
|
+
<provider selected="true" editor-type-id="text-editor">
|
37
|
+
<state vertical-scroll-proportion="0.0">
|
38
|
+
<caret line="1" column="18" selection-start-line="1" selection-start-column="18" selection-end-line="1" selection-end-column="18" />
|
39
|
+
<folding />
|
40
|
+
</state>
|
41
|
+
</provider>
|
42
|
+
</entry>
|
43
|
+
</file>
|
44
|
+
<file leaf-file-name="device_wizard.rb" pinned="false" current-in-tab="true">
|
45
|
+
<entry file="file://$PROJECT_DIR$/lib/device_wizard.rb">
|
46
|
+
<provider selected="true" editor-type-id="text-editor">
|
47
|
+
<state vertical-scroll-proportion="0.1310564">
|
48
|
+
<caret line="17" column="6" selection-start-line="17" selection-start-column="5" selection-end-line="17" selection-end-column="6" />
|
49
|
+
<folding>
|
50
|
+
<element signature="e#56#184#0" expanded="false" />
|
51
|
+
<element signature="e#1135#1982#0" expanded="false" />
|
52
|
+
<element signature="e#1988#2212#0" expanded="false" />
|
53
|
+
<element signature="e#2218#2425#0" expanded="false" />
|
54
|
+
<element signature="e#2669#2767#0" expanded="false" />
|
55
|
+
<element signature="e#2771#2927#0" expanded="false" />
|
56
|
+
<element signature="e#2931#3450#0" expanded="false" />
|
57
|
+
<element signature="e#3454#3997#0" expanded="false" />
|
58
|
+
<element signature="e#4001#4534#0" expanded="false" />
|
59
|
+
<element signature="e#4538#5053#0" expanded="false" />
|
60
|
+
<element signature="e#5057#5168#0" expanded="false" />
|
61
|
+
<element signature="e#5172#5701#0" expanded="false" />
|
62
|
+
<element signature="e#5705#6731#0" expanded="false" />
|
63
|
+
<element signature="e#6735#7308#0" expanded="false" />
|
64
|
+
<element signature="e#7312#7854#0" expanded="false" />
|
65
|
+
</folding>
|
66
|
+
</state>
|
67
|
+
</provider>
|
68
|
+
</entry>
|
69
|
+
</file>
|
70
|
+
<file leaf-file-name=".rspec" pinned="false" current-in-tab="false">
|
71
|
+
<entry file="file://$PROJECT_DIR$/.rspec">
|
72
|
+
<provider selected="true" editor-type-id="text-editor">
|
73
|
+
<state vertical-scroll-proportion="0.0">
|
74
|
+
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
75
|
+
<folding />
|
76
|
+
</state>
|
77
|
+
</provider>
|
78
|
+
</entry>
|
79
|
+
</file>
|
80
|
+
<file leaf-file-name="browser_details_spec.rb" pinned="false" current-in-tab="false">
|
81
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/browser_details_spec.rb">
|
82
|
+
<provider selected="true" editor-type-id="text-editor">
|
83
|
+
<state vertical-scroll-proportion="0.0">
|
84
|
+
<caret line="54" column="45" selection-start-line="54" selection-start-column="45" selection-end-line="54" selection-end-column="45" />
|
85
|
+
<folding />
|
86
|
+
</state>
|
87
|
+
</provider>
|
88
|
+
</entry>
|
89
|
+
</file>
|
90
|
+
<file leaf-file-name="os_details_spec.rb" pinned="false" current-in-tab="false">
|
91
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/os_details_spec.rb">
|
92
|
+
<provider selected="true" editor-type-id="text-editor">
|
93
|
+
<state vertical-scroll-proportion="0.0">
|
94
|
+
<caret line="37" column="35" selection-start-line="37" selection-start-column="35" selection-end-line="37" selection-end-column="35" />
|
95
|
+
<folding />
|
96
|
+
</state>
|
97
|
+
</provider>
|
98
|
+
</entry>
|
99
|
+
</file>
|
100
|
+
<file leaf-file-name="device_wizard_spec.rb" pinned="false" current-in-tab="false">
|
101
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/device_wizard_spec.rb">
|
102
|
+
<provider selected="true" editor-type-id="text-editor">
|
103
|
+
<state vertical-scroll-proportion="0.0">
|
104
|
+
<caret line="151" column="18" selection-start-line="151" selection-start-column="18" selection-end-line="151" selection-end-column="18" />
|
105
|
+
<folding>
|
106
|
+
<element signature="e#124#1880#0" expanded="false" />
|
107
|
+
<element signature="e#1901#2201#0" expanded="false" />
|
108
|
+
<element signature="e#2226#2504#0" expanded="false" />
|
109
|
+
<element signature="e#2525#3370#0" expanded="false" />
|
110
|
+
<element signature="e#3387#3719#0" expanded="false" />
|
111
|
+
<element signature="e#3741#4614#0" expanded="false" />
|
112
|
+
<element signature="e#4636#7436#0" expanded="false" />
|
113
|
+
<element signature="e#7459#7911#0" expanded="false" />
|
114
|
+
</folding>
|
115
|
+
</state>
|
116
|
+
</provider>
|
117
|
+
</entry>
|
118
|
+
</file>
|
119
|
+
<file leaf-file-name="Gemfile" pinned="false" current-in-tab="false">
|
120
|
+
<entry file="file://$PROJECT_DIR$/Gemfile">
|
121
|
+
<provider selected="true" editor-type-id="text-editor">
|
122
|
+
<state vertical-scroll-proportion="0.0">
|
123
|
+
<caret line="5" column="9" selection-start-line="5" selection-start-column="9" selection-end-line="5" selection-end-column="9" />
|
124
|
+
<folding />
|
125
|
+
</state>
|
126
|
+
</provider>
|
127
|
+
</entry>
|
128
|
+
</file>
|
129
|
+
</leaf>
|
130
|
+
</component>
|
131
|
+
<component name="Git.Settings">
|
132
|
+
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
133
|
+
</component>
|
134
|
+
<component name="IdeDocumentHistory">
|
135
|
+
<option name="CHANGED_PATHS">
|
136
|
+
<list>
|
137
|
+
<option value="$PROJECT_DIR$/Gemfile" />
|
138
|
+
<option value="$PROJECT_DIR$/device_wizard.gemspec" />
|
139
|
+
<option value="$PROJECT_DIR$/lib/device_wizard/version.rb" />
|
140
|
+
<option value="$PROJECT_DIR$/spec/device_wizard/browser_details_spec.rb" />
|
141
|
+
<option value="$PROJECT_DIR$/spec/device_wizard/os_details_spec.rb" />
|
142
|
+
<option value="$PROJECT_DIR$/lib/device_wizard.rb" />
|
143
|
+
<option value="$PROJECT_DIR$/spec/device_wizard/device_wizard_spec.rb" />
|
144
|
+
</list>
|
145
|
+
</option>
|
146
|
+
</component>
|
147
|
+
<component name="JsBuildToolGruntFileManager" detection-done="true" />
|
148
|
+
<component name="JsBuildToolPackageJson" detection-done="true" />
|
149
|
+
<component name="JsGulpfileManager">
|
150
|
+
<detection-done>true</detection-done>
|
151
|
+
</component>
|
152
|
+
<component name="ProjectFrameBounds">
|
153
|
+
<option name="x" value="1918" />
|
154
|
+
<option name="y" value="29" />
|
155
|
+
<option name="width" value="2363" />
|
156
|
+
<option name="height" value="1380" />
|
157
|
+
</component>
|
158
|
+
<component name="ProjectLevelVcsManager" settingsEditedManually="false">
|
159
|
+
<OptionsSetting value="true" id="Add" />
|
160
|
+
<OptionsSetting value="true" id="Remove" />
|
161
|
+
<OptionsSetting value="true" id="Checkout" />
|
162
|
+
<OptionsSetting value="true" id="Update" />
|
163
|
+
<OptionsSetting value="true" id="Status" />
|
164
|
+
<OptionsSetting value="true" id="Edit" />
|
165
|
+
<ConfirmationsSetting value="0" id="Add" />
|
166
|
+
<ConfirmationsSetting value="0" id="Remove" />
|
167
|
+
</component>
|
168
|
+
<component name="ProjectView">
|
169
|
+
<navigator currentView="ProjectPane" proportions="" version="1">
|
170
|
+
<flattenPackages />
|
171
|
+
<showMembers />
|
172
|
+
<showModules />
|
173
|
+
<showLibraryContents />
|
174
|
+
<hideEmptyPackages />
|
175
|
+
<abbreviatePackageNames />
|
176
|
+
<autoscrollToSource />
|
177
|
+
<autoscrollFromSource />
|
178
|
+
<sortByType />
|
179
|
+
<manualOrder />
|
180
|
+
<foldersAlwaysOnTop value="true" />
|
181
|
+
</navigator>
|
182
|
+
<panes>
|
183
|
+
<pane id="Scope" />
|
184
|
+
<pane id="Scratches" />
|
185
|
+
<pane id="ProjectPane">
|
186
|
+
<subPane>
|
187
|
+
<PATH>
|
188
|
+
<PATH_ELEMENT>
|
189
|
+
<option name="myItemId" value="device_wizard" />
|
190
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
191
|
+
</PATH_ELEMENT>
|
192
|
+
</PATH>
|
193
|
+
<PATH>
|
194
|
+
<PATH_ELEMENT>
|
195
|
+
<option name="myItemId" value="device_wizard" />
|
196
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
197
|
+
</PATH_ELEMENT>
|
198
|
+
<PATH_ELEMENT>
|
199
|
+
<option name="myItemId" value="device_wizard" />
|
200
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
201
|
+
</PATH_ELEMENT>
|
202
|
+
</PATH>
|
203
|
+
<PATH>
|
204
|
+
<PATH_ELEMENT>
|
205
|
+
<option name="myItemId" value="device_wizard" />
|
206
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
207
|
+
</PATH_ELEMENT>
|
208
|
+
<PATH_ELEMENT>
|
209
|
+
<option name="myItemId" value="device_wizard" />
|
210
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
211
|
+
</PATH_ELEMENT>
|
212
|
+
<PATH_ELEMENT>
|
213
|
+
<option name="myItemId" value="spec" />
|
214
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
215
|
+
</PATH_ELEMENT>
|
216
|
+
</PATH>
|
217
|
+
<PATH>
|
218
|
+
<PATH_ELEMENT>
|
219
|
+
<option name="myItemId" value="device_wizard" />
|
220
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
221
|
+
</PATH_ELEMENT>
|
222
|
+
<PATH_ELEMENT>
|
223
|
+
<option name="myItemId" value="device_wizard" />
|
224
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
225
|
+
</PATH_ELEMENT>
|
226
|
+
<PATH_ELEMENT>
|
227
|
+
<option name="myItemId" value="spec" />
|
228
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
229
|
+
</PATH_ELEMENT>
|
230
|
+
<PATH_ELEMENT>
|
231
|
+
<option name="myItemId" value="device_wizard" />
|
232
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
233
|
+
</PATH_ELEMENT>
|
234
|
+
</PATH>
|
235
|
+
<PATH>
|
236
|
+
<PATH_ELEMENT>
|
237
|
+
<option name="myItemId" value="device_wizard" />
|
238
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
239
|
+
</PATH_ELEMENT>
|
240
|
+
<PATH_ELEMENT>
|
241
|
+
<option name="myItemId" value="device_wizard" />
|
242
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
243
|
+
</PATH_ELEMENT>
|
244
|
+
<PATH_ELEMENT>
|
245
|
+
<option name="myItemId" value="lib" />
|
246
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
247
|
+
</PATH_ELEMENT>
|
248
|
+
</PATH>
|
249
|
+
<PATH>
|
250
|
+
<PATH_ELEMENT>
|
251
|
+
<option name="myItemId" value="device_wizard" />
|
252
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
253
|
+
</PATH_ELEMENT>
|
254
|
+
<PATH_ELEMENT>
|
255
|
+
<option name="myItemId" value="device_wizard" />
|
256
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
257
|
+
</PATH_ELEMENT>
|
258
|
+
<PATH_ELEMENT>
|
259
|
+
<option name="myItemId" value="lib" />
|
260
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
261
|
+
</PATH_ELEMENT>
|
262
|
+
<PATH_ELEMENT>
|
263
|
+
<option name="myItemId" value="device_wizard" />
|
264
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
265
|
+
</PATH_ELEMENT>
|
266
|
+
</PATH>
|
267
|
+
</subPane>
|
268
|
+
</pane>
|
269
|
+
</panes>
|
270
|
+
</component>
|
271
|
+
<component name="PropertiesComponent">
|
272
|
+
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
|
273
|
+
<property name="WebServerToolWindowFactoryState" value="false" />
|
274
|
+
<property name="FullScreen" value="false" />
|
275
|
+
<property name="js-jscs-nodeInterpreter" value="/usr/local/bin/node" />
|
276
|
+
</component>
|
277
|
+
<component name="RecentsManager">
|
278
|
+
<key name="CopyFile.RECENT_KEYS">
|
279
|
+
<recent name="$PROJECT_DIR$/spec/device_wizard" />
|
280
|
+
</key>
|
281
|
+
</component>
|
282
|
+
<component name="RunManager">
|
283
|
+
<configuration default="true" type="CucumberRunConfigurationType" factoryName="Cucumber">
|
284
|
+
<predefined_log_file id="RUBY_CUCUMBER" enabled="true" />
|
285
|
+
<module name="" />
|
286
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
287
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
288
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
289
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
290
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
291
|
+
<envs />
|
292
|
+
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
293
|
+
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
294
|
+
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
295
|
+
<COVERAGE_PATTERN ENABLED="true">
|
296
|
+
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
297
|
+
</COVERAGE_PATTERN>
|
298
|
+
</EXTENSION>
|
299
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="**/*.feature" />
|
300
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
|
301
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
|
302
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
|
303
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_TAGS_FILTER" VALUE="" />
|
304
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_NAME_FILTER" VALUE="" />
|
305
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="CUCUMBER_ARGS" VALUE="--color -r features" />
|
306
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_VERSION" VALUE="" />
|
307
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="FULL_BACKTRACE" VALUE="false" />
|
308
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="VERBOSE_OPTION" VALUE="false" />
|
309
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
|
310
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
|
311
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
|
312
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="CUCUMBER_RUNNER_PATH" VALUE="" />
|
313
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="USE_CUSTOM_RUNNER" VALUE="false" />
|
314
|
+
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SETTINGS_VERSION" VALUE="2" />
|
315
|
+
<method />
|
316
|
+
</configuration>
|
317
|
+
<configuration default="true" type="JavascriptDebugType" factoryName="JavaScript Debug">
|
318
|
+
<method />
|
319
|
+
</configuration>
|
320
|
+
<configuration default="true" type="RSpecRunConfigurationType" factoryName="RSpec">
|
321
|
+
<predefined_log_file id="RUBY_RSPEC" enabled="true" />
|
322
|
+
<module name="" />
|
323
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
324
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
325
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
326
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
327
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
328
|
+
<envs />
|
329
|
+
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
330
|
+
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
331
|
+
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
332
|
+
<COVERAGE_PATTERN ENABLED="true">
|
333
|
+
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
334
|
+
</COVERAGE_PATTERN>
|
335
|
+
</EXTENSION>
|
336
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
|
337
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
|
338
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_RUNNER_PATH" VALUE="" />
|
339
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="**/*_spec.rb" />
|
340
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_EXAMPLE_NAME" VALUE="" />
|
341
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
|
342
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_ARGS" VALUE="" />
|
343
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_VERSION" VALUE="" />
|
344
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="USE_CUSTOM_SPEC_RUNNER" VALUE="false" />
|
345
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
|
346
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
|
347
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
|
348
|
+
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="FULL_BACKTRACE" VALUE="false" />
|
349
|
+
<method />
|
350
|
+
</configuration>
|
351
|
+
<configuration default="true" type="RubyRunConfigurationType" factoryName="Ruby">
|
352
|
+
<module name="" />
|
353
|
+
<RUBY_RUN_CONFIG NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
354
|
+
<RUBY_RUN_CONFIG NAME="WORK DIR" VALUE="" />
|
355
|
+
<RUBY_RUN_CONFIG NAME="SHOULD_USE_SDK" VALUE="false" />
|
356
|
+
<RUBY_RUN_CONFIG NAME="ALTERN_SDK_NAME" VALUE="" />
|
357
|
+
<RUBY_RUN_CONFIG NAME="myPassParentEnvs" VALUE="true" />
|
358
|
+
<envs />
|
359
|
+
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
360
|
+
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
361
|
+
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
362
|
+
<COVERAGE_PATTERN ENABLED="true">
|
363
|
+
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
364
|
+
</COVERAGE_PATTERN>
|
365
|
+
</EXTENSION>
|
366
|
+
<RUBY_RUN_CONFIG NAME="SCRIPT_PATH" VALUE="" />
|
367
|
+
<RUBY_RUN_CONFIG NAME="SCRIPT_ARGS" VALUE="" />
|
368
|
+
<method />
|
369
|
+
</configuration>
|
370
|
+
<configuration default="true" type="TestUnitRunConfigurationType" factoryName="Test::Unit/Shoulda/Minitest">
|
371
|
+
<predefined_log_file id="RUBY_TESTUNIT" enabled="true" />
|
372
|
+
<module name="" />
|
373
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
374
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
375
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
376
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
377
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
378
|
+
<envs />
|
379
|
+
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
380
|
+
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
381
|
+
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
382
|
+
<COVERAGE_PATTERN ENABLED="true">
|
383
|
+
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
384
|
+
</COVERAGE_PATTERN>
|
385
|
+
</EXTENSION>
|
386
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
|
387
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
|
388
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="" />
|
389
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_METHOD_NAME" VALUE="" />
|
390
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
|
391
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
|
392
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
|
393
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
|
394
|
+
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_OPTIONS" VALUE="" />
|
395
|
+
<method />
|
396
|
+
</configuration>
|
397
|
+
<configuration default="true" type="js.build_tools.gulp" factoryName="Gulp.js">
|
398
|
+
<node-options />
|
399
|
+
<gulpfile />
|
400
|
+
<tasks />
|
401
|
+
<arguments />
|
402
|
+
<pass-parent-envs>true</pass-parent-envs>
|
403
|
+
<envs />
|
404
|
+
<method />
|
405
|
+
</configuration>
|
406
|
+
<configuration default="true" type="js.build_tools.npm" factoryName="npm">
|
407
|
+
<command value="run-script" />
|
408
|
+
<scripts />
|
409
|
+
<envs />
|
410
|
+
<method />
|
411
|
+
</configuration>
|
412
|
+
</component>
|
413
|
+
<component name="ShelveChangesManager" show_recycled="false" />
|
414
|
+
<component name="SvnConfiguration">
|
415
|
+
<configuration />
|
416
|
+
</component>
|
417
|
+
<component name="TaskManager">
|
418
|
+
<task active="true" id="Default" summary="Default task">
|
419
|
+
<changelist id="d61b7375-c87d-4649-8619-301d696e3e1d" name="Default" comment="" />
|
420
|
+
<created>1455788014349</created>
|
421
|
+
<option name="number" value="Default" />
|
422
|
+
<updated>1455788014349</updated>
|
423
|
+
</task>
|
424
|
+
<servers />
|
425
|
+
</component>
|
426
|
+
<component name="ToolWindowManager">
|
427
|
+
<frame x="1918" y="29" width="2363" height="1380" extended-state="0" />
|
428
|
+
<editor active="false" />
|
429
|
+
<layout>
|
430
|
+
<window_info id="Project" active="true" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.25161567" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
431
|
+
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
|
432
|
+
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
|
433
|
+
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
434
|
+
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
435
|
+
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
436
|
+
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
437
|
+
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
438
|
+
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" />
|
439
|
+
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
440
|
+
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
|
441
|
+
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
442
|
+
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
443
|
+
<window_info id="Application Servers" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
444
|
+
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
|
445
|
+
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
|
446
|
+
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
447
|
+
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
448
|
+
</layout>
|
449
|
+
<layout-to-restore>
|
450
|
+
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
|
451
|
+
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
|
452
|
+
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
453
|
+
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
454
|
+
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
|
455
|
+
<window_info id="Application Servers" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
|
456
|
+
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
|
457
|
+
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
|
458
|
+
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
459
|
+
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
|
460
|
+
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.25179857" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
461
|
+
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
|
462
|
+
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
463
|
+
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
464
|
+
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
465
|
+
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
466
|
+
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" />
|
467
|
+
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
468
|
+
</layout-to-restore>
|
469
|
+
</component>
|
470
|
+
<component name="Vcs.Log.UiProperties">
|
471
|
+
<option name="RECENTLY_FILTERED_USER_GROUPS">
|
472
|
+
<collection />
|
473
|
+
</option>
|
474
|
+
<option name="RECENTLY_FILTERED_BRANCH_GROUPS">
|
475
|
+
<collection />
|
476
|
+
</option>
|
477
|
+
</component>
|
478
|
+
<component name="VcsContentAnnotationSettings">
|
479
|
+
<option name="myLimit" value="2678400000" />
|
480
|
+
</component>
|
481
|
+
<component name="XDebuggerManager">
|
482
|
+
<breakpoint-manager>
|
483
|
+
<option name="time" value="6" />
|
484
|
+
</breakpoint-manager>
|
485
|
+
<watches-manager />
|
486
|
+
</component>
|
487
|
+
<component name="editorHistoryManager">
|
488
|
+
<entry file="file://$PROJECT_DIR$/device_wizard.gemspec">
|
489
|
+
<provider selected="true" editor-type-id="text-editor">
|
490
|
+
<state vertical-scroll-proportion="0.0">
|
491
|
+
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
492
|
+
<folding />
|
493
|
+
</state>
|
494
|
+
</provider>
|
495
|
+
</entry>
|
496
|
+
<entry file="file://$PROJECT_DIR$/.rspec">
|
497
|
+
<provider selected="true" editor-type-id="text-editor">
|
498
|
+
<state vertical-scroll-proportion="0.0">
|
499
|
+
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
500
|
+
<folding />
|
501
|
+
</state>
|
502
|
+
</provider>
|
503
|
+
</entry>
|
504
|
+
<entry file="file://$PROJECT_DIR$/lib/device_wizard.rb">
|
505
|
+
<provider selected="true" editor-type-id="text-editor">
|
506
|
+
<state vertical-scroll-proportion="0.0">
|
507
|
+
<caret line="77" column="0" selection-start-line="77" selection-start-column="0" selection-end-line="77" selection-end-column="0" />
|
508
|
+
<folding>
|
509
|
+
<element signature="e#56#184#0" expanded="false" />
|
510
|
+
<element signature="e#1135#1982#0" expanded="false" />
|
511
|
+
<element signature="e#1988#2212#0" expanded="false" />
|
512
|
+
<element signature="e#2218#2425#0" expanded="false" />
|
513
|
+
<element signature="e#2669#2767#0" expanded="false" />
|
514
|
+
<element signature="e#2771#2927#0" expanded="false" />
|
515
|
+
<element signature="e#2931#3450#0" expanded="false" />
|
516
|
+
<element signature="e#3454#3997#0" expanded="false" />
|
517
|
+
<element signature="e#4001#4534#0" expanded="false" />
|
518
|
+
<element signature="e#4538#5053#0" expanded="false" />
|
519
|
+
<element signature="e#5057#5168#0" expanded="false" />
|
520
|
+
<element signature="e#5172#5701#0" expanded="false" />
|
521
|
+
<element signature="e#5705#6731#0" expanded="false" />
|
522
|
+
<element signature="e#6735#7308#0" expanded="false" />
|
523
|
+
<element signature="e#7312#7854#0" expanded="false" />
|
524
|
+
</folding>
|
525
|
+
</state>
|
526
|
+
</provider>
|
527
|
+
</entry>
|
528
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/device_wizard_spec.rb">
|
529
|
+
<provider selected="true" editor-type-id="text-editor">
|
530
|
+
<state vertical-scroll-proportion="0.0">
|
531
|
+
<caret line="158" column="109" selection-start-line="158" selection-start-column="109" selection-end-line="158" selection-end-column="109" />
|
532
|
+
<folding>
|
533
|
+
<element signature="e#124#1880#0" expanded="false" />
|
534
|
+
<element signature="e#1901#2201#0" expanded="false" />
|
535
|
+
<element signature="e#2226#2504#0" expanded="false" />
|
536
|
+
<element signature="e#2525#3370#0" expanded="false" />
|
537
|
+
<element signature="e#3387#3719#0" expanded="false" />
|
538
|
+
<element signature="e#3741#4614#0" expanded="false" />
|
539
|
+
<element signature="e#4636#7436#0" expanded="false" />
|
540
|
+
<element signature="e#7459#7911#0" expanded="false" />
|
541
|
+
</folding>
|
542
|
+
</state>
|
543
|
+
</provider>
|
544
|
+
</entry>
|
545
|
+
<entry file="file://$PROJECT_DIR$/Gemfile">
|
546
|
+
<provider selected="true" editor-type-id="text-editor">
|
547
|
+
<state vertical-scroll-proportion="0.0">
|
548
|
+
<caret line="5" column="9" selection-start-line="5" selection-start-column="9" selection-end-line="5" selection-end-column="9" />
|
549
|
+
<folding />
|
550
|
+
</state>
|
551
|
+
</provider>
|
552
|
+
</entry>
|
553
|
+
<entry file="file://$PROJECT_DIR$/device_wizard.gemspec">
|
554
|
+
<provider selected="true" editor-type-id="text-editor">
|
555
|
+
<state vertical-scroll-proportion="0.0">
|
556
|
+
<caret line="19" column="30" selection-start-line="19" selection-start-column="30" selection-end-line="19" selection-end-column="30" />
|
557
|
+
<folding />
|
558
|
+
</state>
|
559
|
+
</provider>
|
560
|
+
</entry>
|
561
|
+
<entry file="file://$PROJECT_DIR$/.rspec">
|
562
|
+
<provider selected="true" editor-type-id="text-editor">
|
563
|
+
<state vertical-scroll-proportion="0.0">
|
564
|
+
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
565
|
+
<folding />
|
566
|
+
</state>
|
567
|
+
</provider>
|
568
|
+
</entry>
|
569
|
+
<entry file="file://$PROJECT_DIR$/lib/device_wizard.rb">
|
570
|
+
<provider selected="true" editor-type-id="text-editor">
|
571
|
+
<state vertical-scroll-proportion="0.0">
|
572
|
+
<caret line="77" column="0" selection-start-line="77" selection-start-column="0" selection-end-line="77" selection-end-column="0" />
|
573
|
+
<folding>
|
574
|
+
<element signature="e#56#184#0" expanded="false" />
|
575
|
+
<element signature="e#1135#1982#0" expanded="false" />
|
576
|
+
<element signature="e#1988#2212#0" expanded="false" />
|
577
|
+
<element signature="e#2218#2425#0" expanded="false" />
|
578
|
+
<element signature="e#2669#2767#0" expanded="false" />
|
579
|
+
<element signature="e#2771#2927#0" expanded="false" />
|
580
|
+
<element signature="e#2931#3450#0" expanded="false" />
|
581
|
+
<element signature="e#3454#3997#0" expanded="false" />
|
582
|
+
<element signature="e#4001#4534#0" expanded="false" />
|
583
|
+
<element signature="e#4538#5053#0" expanded="false" />
|
584
|
+
<element signature="e#5057#5168#0" expanded="false" />
|
585
|
+
<element signature="e#5172#5701#0" expanded="false" />
|
586
|
+
<element signature="e#5705#6731#0" expanded="false" />
|
587
|
+
<element signature="e#6735#7308#0" expanded="false" />
|
588
|
+
<element signature="e#7312#7854#0" expanded="false" />
|
589
|
+
</folding>
|
590
|
+
</state>
|
591
|
+
</provider>
|
592
|
+
</entry>
|
593
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/device_wizard_spec.rb">
|
594
|
+
<provider selected="true" editor-type-id="text-editor">
|
595
|
+
<state vertical-scroll-proportion="0.0">
|
596
|
+
<caret line="158" column="109" selection-start-line="158" selection-start-column="109" selection-end-line="158" selection-end-column="109" />
|
597
|
+
<folding>
|
598
|
+
<element signature="e#124#1880#0" expanded="false" />
|
599
|
+
<element signature="e#1901#2201#0" expanded="false" />
|
600
|
+
<element signature="e#2226#2504#0" expanded="false" />
|
601
|
+
<element signature="e#2525#3370#0" expanded="false" />
|
602
|
+
<element signature="e#3387#3719#0" expanded="false" />
|
603
|
+
<element signature="e#3741#4614#0" expanded="false" />
|
604
|
+
<element signature="e#4636#7436#0" expanded="false" />
|
605
|
+
<element signature="e#7459#7911#0" expanded="false" />
|
606
|
+
</folding>
|
607
|
+
</state>
|
608
|
+
</provider>
|
609
|
+
</entry>
|
610
|
+
<entry file="file://$PROJECT_DIR$/Gemfile">
|
611
|
+
<provider selected="true" editor-type-id="text-editor">
|
612
|
+
<state vertical-scroll-proportion="0.0">
|
613
|
+
<caret line="5" column="9" selection-start-line="5" selection-start-column="9" selection-end-line="5" selection-end-column="9" />
|
614
|
+
<folding />
|
615
|
+
</state>
|
616
|
+
</provider>
|
617
|
+
</entry>
|
618
|
+
<entry file="file://$PROJECT_DIR$/device_wizard.gemspec">
|
619
|
+
<provider selected="true" editor-type-id="text-editor">
|
620
|
+
<state vertical-scroll-proportion="0.0">
|
621
|
+
<caret line="19" column="30" selection-start-line="19" selection-start-column="30" selection-end-line="19" selection-end-column="30" />
|
622
|
+
<folding />
|
623
|
+
</state>
|
624
|
+
</provider>
|
625
|
+
</entry>
|
626
|
+
<entry file="file://$PROJECT_DIR$/.rspec">
|
627
|
+
<provider selected="true" editor-type-id="text-editor">
|
628
|
+
<state vertical-scroll-proportion="0.0">
|
629
|
+
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
630
|
+
<folding />
|
631
|
+
</state>
|
632
|
+
</provider>
|
633
|
+
</entry>
|
634
|
+
<entry file="file://$PROJECT_DIR$/Gemfile">
|
635
|
+
<provider selected="true" editor-type-id="text-editor">
|
636
|
+
<state vertical-scroll-proportion="0.0">
|
637
|
+
<caret line="5" column="9" selection-start-line="5" selection-start-column="9" selection-end-line="5" selection-end-column="9" />
|
638
|
+
<folding />
|
639
|
+
</state>
|
640
|
+
</provider>
|
641
|
+
</entry>
|
642
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/os_details_spec.rb">
|
643
|
+
<provider selected="true" editor-type-id="text-editor">
|
644
|
+
<state vertical-scroll-proportion="0.0">
|
645
|
+
<caret line="37" column="35" selection-start-line="37" selection-start-column="35" selection-end-line="37" selection-end-column="35" />
|
646
|
+
<folding />
|
647
|
+
</state>
|
648
|
+
</provider>
|
649
|
+
</entry>
|
650
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/browser_details_spec.rb">
|
651
|
+
<provider selected="true" editor-type-id="text-editor">
|
652
|
+
<state vertical-scroll-proportion="0.0">
|
653
|
+
<caret line="54" column="45" selection-start-line="54" selection-start-column="45" selection-end-line="54" selection-end-column="45" />
|
654
|
+
<folding />
|
655
|
+
</state>
|
656
|
+
</provider>
|
657
|
+
</entry>
|
658
|
+
<entry file="file://$PROJECT_DIR$/spec/device_wizard/device_wizard_spec.rb">
|
659
|
+
<provider selected="true" editor-type-id="text-editor">
|
660
|
+
<state vertical-scroll-proportion="0.0">
|
661
|
+
<caret line="151" column="18" selection-start-line="151" selection-start-column="18" selection-end-line="151" selection-end-column="18" />
|
662
|
+
<folding>
|
663
|
+
<element signature="e#124#1880#0" expanded="false" />
|
664
|
+
<element signature="e#1901#2201#0" expanded="false" />
|
665
|
+
<element signature="e#2226#2504#0" expanded="false" />
|
666
|
+
<element signature="e#2525#3370#0" expanded="false" />
|
667
|
+
<element signature="e#3387#3719#0" expanded="false" />
|
668
|
+
<element signature="e#3741#4614#0" expanded="false" />
|
669
|
+
<element signature="e#4636#7436#0" expanded="false" />
|
670
|
+
<element signature="e#7459#7911#0" expanded="false" />
|
671
|
+
</folding>
|
672
|
+
</state>
|
673
|
+
</provider>
|
674
|
+
</entry>
|
675
|
+
<entry file="file://$PROJECT_DIR$/lib/device_wizard/version.rb">
|
676
|
+
<provider selected="true" editor-type-id="text-editor">
|
677
|
+
<state vertical-scroll-proportion="0.0">
|
678
|
+
<caret line="1" column="18" selection-start-line="1" selection-start-column="18" selection-end-line="1" selection-end-column="18" />
|
679
|
+
<folding />
|
680
|
+
</state>
|
681
|
+
</provider>
|
682
|
+
</entry>
|
683
|
+
<entry file="file://$PROJECT_DIR$/lib/device_wizard.rb">
|
684
|
+
<provider selected="true" editor-type-id="text-editor">
|
685
|
+
<state vertical-scroll-proportion="0.1310564">
|
686
|
+
<caret line="17" column="6" selection-start-line="17" selection-start-column="5" selection-end-line="17" selection-end-column="6" />
|
687
|
+
<folding>
|
688
|
+
<element signature="e#56#184#0" expanded="false" />
|
689
|
+
<element signature="e#1135#1982#0" expanded="false" />
|
690
|
+
<element signature="e#1988#2212#0" expanded="false" />
|
691
|
+
<element signature="e#2218#2425#0" expanded="false" />
|
692
|
+
<element signature="e#2669#2767#0" expanded="false" />
|
693
|
+
<element signature="e#2771#2927#0" expanded="false" />
|
694
|
+
<element signature="e#2931#3450#0" expanded="false" />
|
695
|
+
<element signature="e#3454#3997#0" expanded="false" />
|
696
|
+
<element signature="e#4001#4534#0" expanded="false" />
|
697
|
+
<element signature="e#4538#5053#0" expanded="false" />
|
698
|
+
<element signature="e#5057#5168#0" expanded="false" />
|
699
|
+
<element signature="e#5172#5701#0" expanded="false" />
|
700
|
+
<element signature="e#5705#6731#0" expanded="false" />
|
701
|
+
<element signature="e#6735#7308#0" expanded="false" />
|
702
|
+
<element signature="e#7312#7854#0" expanded="false" />
|
703
|
+
</folding>
|
704
|
+
</state>
|
705
|
+
</provider>
|
706
|
+
</entry>
|
707
|
+
</component>
|
708
|
+
</project>
|
data/README.md
CHANGED
@@ -1,8 +1,10 @@
|
|
1
1
|
# DeviceWizard
|
2
2
|
|
3
|
-
Welcome to
|
3
|
+
Welcome to DeviceWizard!
|
4
4
|
|
5
|
-
|
5
|
+
The super fast, ultra light weight device detection framework.
|
6
|
+
|
7
|
+
Because DeviceWizard is not based on any lookup dictionaries it is future proof and does not need updating when new devices come out, and because it's not based on any lookup dictionaries it is super fast and small in size.
|
6
8
|
|
7
9
|
## Installation
|
8
10
|
|
@@ -22,7 +24,25 @@ Or install it yourself as:
|
|
22
24
|
|
23
25
|
## Usage
|
24
26
|
|
25
|
-
|
27
|
+
#create the user agent detector
|
28
|
+
detector = DeviceWizard::UserAgentDetector.new
|
29
|
+
|
30
|
+
#pass the user agent to the detector
|
31
|
+
device_type = detector.get_device_type(user_agent_string)
|
32
|
+
|
33
|
+
The detected device type will be one of the following:
|
34
|
+
- **desktop**
|
35
|
+
- **tablet**
|
36
|
+
- **mobile**
|
37
|
+
- **crawler**
|
38
|
+
- **unknown**
|
39
|
+
|
40
|
+
To improve performance in your application when using device detector we recommend that you only check the device type on the first request and either store the result in the session or a cookie to prevent having to recalculate the device type on each request.
|
41
|
+
|
42
|
+
## Upcoming Features
|
43
|
+
|
44
|
+
- **Browser Detection**: determine the browser the request was sent from (e.g. chrome/ firefox / internet explorer / or safari etc..)
|
45
|
+
- **OS Detection**: determine the OS and version the request was sent from (e.g. Windows 10 / IOS 9 etc..)
|
26
46
|
|
27
47
|
## Development
|
28
48
|
|
@@ -32,7 +52,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
32
52
|
|
33
53
|
## Contributing
|
34
54
|
|
35
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
55
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/vaughanbrittonsage/device_wizard. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
|
36
56
|
|
37
57
|
|
38
58
|
## License
|
data/lib/device_wizard.rb
CHANGED
@@ -30,6 +30,20 @@ module DeviceWizard
|
|
30
30
|
REGEX_CRAWLER = /(spider|crawl|slurp|bot)/
|
31
31
|
#########
|
32
32
|
|
33
|
+
def initialize
|
34
|
+
@browser_resolvers = []
|
35
|
+
@browser_resolvers.push(FirefoxResolver.new)
|
36
|
+
@browser_resolvers.push(GoogleChromeResolver.new)
|
37
|
+
@browser_resolvers.push(InternetExplorerResolver.new)
|
38
|
+
@browser_resolvers.push(SafariResolver.new)
|
39
|
+
|
40
|
+
@os_resolvers = []
|
41
|
+
@os_resolvers.push(AndroidResolver.new)
|
42
|
+
@os_resolvers.push(IOSResolver.new)
|
43
|
+
@os_resolvers.push(MacResolver.new)
|
44
|
+
@os_resolvers.push(WindowsResolver.new)
|
45
|
+
end
|
46
|
+
|
33
47
|
def get_device_type(user_agent)
|
34
48
|
|
35
49
|
if user_agent.to_s.strip.length == 0
|
@@ -72,6 +86,333 @@ module DeviceWizard
|
|
72
86
|
|
73
87
|
end
|
74
88
|
|
89
|
+
def get_browser(user_agent)
|
90
|
+
|
91
|
+
@browser_resolvers.each do |r|
|
92
|
+
|
93
|
+
browser = r.identify(user_agent)
|
94
|
+
|
95
|
+
if browser != nil
|
96
|
+
return browser
|
97
|
+
end
|
98
|
+
|
99
|
+
end
|
100
|
+
|
101
|
+
return BrowserDetails.new
|
102
|
+
|
103
|
+
end
|
104
|
+
|
105
|
+
def get_os(user_agent)
|
106
|
+
|
107
|
+
@os_resolvers.each do |r|
|
108
|
+
|
109
|
+
os = r.identify(user_agent)
|
110
|
+
|
111
|
+
if os != nil
|
112
|
+
return os
|
113
|
+
end
|
114
|
+
|
115
|
+
end
|
116
|
+
|
117
|
+
return OperatingSystemDetails.new
|
118
|
+
|
119
|
+
end
|
120
|
+
|
121
|
+
def get_details(user_agent)
|
122
|
+
details = DeviceDetails.new
|
123
|
+
|
124
|
+
details.type = get_device_type(user_agent)
|
125
|
+
details.browser = get_browser(user_agent)
|
126
|
+
details.os = get_os(user_agent)
|
127
|
+
|
128
|
+
return details
|
129
|
+
end
|
130
|
+
|
131
|
+
end
|
132
|
+
|
133
|
+
class DeviceDetails
|
134
|
+
attr_accessor :type
|
135
|
+
attr_accessor :browser
|
136
|
+
attr_accessor :os
|
137
|
+
end
|
138
|
+
|
139
|
+
class BrowserDetails
|
140
|
+
attr_accessor :name
|
141
|
+
attr_accessor :version
|
142
|
+
|
143
|
+
def initialize
|
144
|
+
@name = 'Unknown'
|
145
|
+
@version = 'Unknown'
|
146
|
+
end
|
147
|
+
end
|
148
|
+
|
149
|
+
class FirefoxResolver
|
150
|
+
|
151
|
+
KEYWORD = 'firefox'
|
152
|
+
REGEX = Regexp.new('firefox/([0-9]+.[0-9])')
|
153
|
+
|
154
|
+
def get_version(user_agent)
|
155
|
+
user_agent.downcase!
|
156
|
+
result = 'Unknown'
|
157
|
+
|
158
|
+
if REGEX =~ user_agent
|
159
|
+
result = $1
|
160
|
+
end
|
161
|
+
end
|
162
|
+
|
163
|
+
def identify(user_agent)
|
164
|
+
user_agent.downcase!
|
165
|
+
|
166
|
+
if !user_agent.include? KEYWORD
|
167
|
+
return nil
|
168
|
+
end
|
169
|
+
|
170
|
+
result = BrowserDetails.new
|
171
|
+
result.name = 'Firefox'
|
172
|
+
result.version = get_version(user_agent)
|
173
|
+
return result
|
174
|
+
end
|
175
|
+
end
|
176
|
+
|
177
|
+
class GoogleChromeResolver
|
178
|
+
|
179
|
+
KEYWORD = 'chrome'
|
180
|
+
REGEX = Regexp.new('chrome/([0-9]+.[0-9]+.[0-9]+.[0-9])')
|
181
|
+
|
182
|
+
def get_version(user_agent)
|
183
|
+
user_agent.downcase!
|
184
|
+
result = 'Unknown'
|
185
|
+
|
186
|
+
if REGEX =~ user_agent
|
187
|
+
result = $1
|
188
|
+
end
|
189
|
+
end
|
190
|
+
|
191
|
+
def identify(user_agent)
|
192
|
+
user_agent.downcase!
|
193
|
+
|
194
|
+
if !user_agent.include? KEYWORD
|
195
|
+
return nil
|
196
|
+
end
|
197
|
+
|
198
|
+
result = BrowserDetails.new
|
199
|
+
result.name = 'Google Chrome'
|
200
|
+
result.version = get_version(user_agent)
|
201
|
+
return result
|
202
|
+
end
|
203
|
+
|
204
|
+
end
|
205
|
+
|
206
|
+
class InternetExplorerResolver
|
207
|
+
|
208
|
+
KEYWORD = 'msie'
|
209
|
+
REGEX = Regexp.new('msie ([0-9]+.[0-9])')
|
210
|
+
|
211
|
+
def get_version(user_agent)
|
212
|
+
user_agent.downcase!
|
213
|
+
result = 'Unknown'
|
214
|
+
|
215
|
+
if REGEX =~ user_agent
|
216
|
+
result = $1
|
217
|
+
end
|
218
|
+
end
|
219
|
+
|
220
|
+
def identify(user_agent)
|
221
|
+
user_agent.downcase!
|
222
|
+
|
223
|
+
if !user_agent.include? KEYWORD
|
224
|
+
return nil
|
225
|
+
end
|
226
|
+
|
227
|
+
result = BrowserDetails.new
|
228
|
+
result.name = 'Internet Explorer'
|
229
|
+
result.version = get_version(user_agent)
|
230
|
+
return result
|
231
|
+
end
|
232
|
+
|
233
|
+
end
|
234
|
+
|
235
|
+
class SafariResolver
|
236
|
+
|
237
|
+
KEYWORD = 'safari'
|
238
|
+
REGEX = Regexp.new('safari/([\.0-9]{3,})')
|
239
|
+
|
240
|
+
def get_version(user_agent)
|
241
|
+
user_agent.downcase!
|
242
|
+
result = 'Unknown'
|
243
|
+
|
244
|
+
if REGEX =~ user_agent
|
245
|
+
result = $1
|
246
|
+
end
|
247
|
+
end
|
248
|
+
|
249
|
+
def identify(user_agent)
|
250
|
+
user_agent.downcase!
|
251
|
+
|
252
|
+
if !user_agent.include? KEYWORD
|
253
|
+
return nil
|
254
|
+
end
|
255
|
+
|
256
|
+
result = BrowserDetails.new
|
257
|
+
result.name = 'Safari'
|
258
|
+
result.version = get_version(user_agent)
|
259
|
+
return result
|
260
|
+
end
|
261
|
+
|
262
|
+
end
|
263
|
+
|
264
|
+
class OperatingSystemDetails
|
265
|
+
|
266
|
+
attr_accessor :name
|
267
|
+
attr_accessor :type
|
268
|
+
attr_accessor :version
|
269
|
+
|
270
|
+
end
|
271
|
+
|
272
|
+
class AndroidResolver
|
273
|
+
|
274
|
+
KEYWORD = 'android'
|
275
|
+
REGEX = Regexp.new('android (\d+(?:\.\d+)+)')
|
276
|
+
|
277
|
+
def get_version(user_agent)
|
278
|
+
user_agent.downcase!
|
279
|
+
result = 'Unknown'
|
280
|
+
|
281
|
+
if REGEX =~ user_agent
|
282
|
+
result = $1
|
283
|
+
end
|
284
|
+
end
|
285
|
+
|
286
|
+
def identify(user_agent)
|
287
|
+
user_agent.downcase!
|
288
|
+
|
289
|
+
if !user_agent.include? KEYWORD
|
290
|
+
return nil
|
291
|
+
end
|
292
|
+
|
293
|
+
result = OperatingSystemDetails.new
|
294
|
+
result.name = 'Android'
|
295
|
+
result.version = get_version(user_agent)
|
296
|
+
return result
|
297
|
+
end
|
298
|
+
|
299
|
+
end
|
300
|
+
|
301
|
+
class IOSResolver
|
302
|
+
|
303
|
+
IPHONE = 'iphone'
|
304
|
+
IPAD = 'ipad'
|
305
|
+
IPOD = 'ipod'
|
306
|
+
REGEX = Regexp.new('os ((\d+_?){2,3})\s')
|
307
|
+
|
308
|
+
def get_version(user_agent)
|
309
|
+
user_agent.downcase!
|
310
|
+
result = 'Unknown'
|
311
|
+
|
312
|
+
if REGEX =~ user_agent
|
313
|
+
result = $1
|
314
|
+
end
|
315
|
+
|
316
|
+
return result.gsub('_','.')
|
317
|
+
end
|
318
|
+
|
319
|
+
def get_type(user_agent)
|
320
|
+
user_agent.downcase!
|
321
|
+
|
322
|
+
if user_agent.include? IPOD
|
323
|
+
return 'IPod'
|
324
|
+
end
|
325
|
+
|
326
|
+
if user_agent.include? IPAD
|
327
|
+
return 'IPad'
|
328
|
+
end
|
329
|
+
|
330
|
+
if user_agent.include? IPHONE
|
331
|
+
return 'IPhone'
|
332
|
+
end
|
333
|
+
|
334
|
+
return 'Unknown'
|
335
|
+
end
|
336
|
+
|
337
|
+
def identify(user_agent)
|
338
|
+
user_agent.downcase!
|
339
|
+
|
340
|
+
if !user_agent.include? IPHONE
|
341
|
+
if !user_agent.include? IPAD
|
342
|
+
if !user_agent.include? IPOD
|
343
|
+
return nil
|
344
|
+
end
|
345
|
+
end
|
346
|
+
end
|
347
|
+
|
348
|
+
result = OperatingSystemDetails.new
|
349
|
+
result.name = 'IOS'
|
350
|
+
result.type = get_type(user_agent)
|
351
|
+
result.version = get_version(user_agent)
|
352
|
+
return result
|
353
|
+
end
|
354
|
+
|
75
355
|
end
|
76
356
|
|
357
|
+
class MacResolver
|
358
|
+
|
359
|
+
KEYWORD = 'intel mac os x'
|
360
|
+
REGEX = Regexp.new('intel mac os x ([0-9]+_[0-9])')
|
361
|
+
|
362
|
+
def get_version(user_agent)
|
363
|
+
user_agent.downcase!
|
364
|
+
result = 'Unknown'
|
365
|
+
|
366
|
+
if REGEX =~ user_agent
|
367
|
+
result = $1
|
368
|
+
end
|
369
|
+
|
370
|
+
return result.gsub('_','.')
|
371
|
+
end
|
372
|
+
|
373
|
+
def identify(user_agent)
|
374
|
+
user_agent.downcase!
|
375
|
+
|
376
|
+
if !user_agent.include? KEYWORD
|
377
|
+
return nil
|
378
|
+
end
|
379
|
+
|
380
|
+
result = OperatingSystemDetails.new
|
381
|
+
result.name = 'Mac OSX'
|
382
|
+
result.version = get_version(user_agent)
|
383
|
+
return result
|
384
|
+
end
|
385
|
+
|
386
|
+
end
|
387
|
+
|
388
|
+
class WindowsResolver
|
389
|
+
|
390
|
+
KEYWORD = 'windows nt'
|
391
|
+
REGEX = Regexp.new('windows nt ([0-9]{1,}[\.0-9]{0,})')
|
392
|
+
|
393
|
+
def get_version(user_agent)
|
394
|
+
user_agent.downcase!
|
395
|
+
result = 'Unknown'
|
396
|
+
|
397
|
+
if REGEX =~ user_agent
|
398
|
+
result = $1
|
399
|
+
end
|
400
|
+
end
|
401
|
+
|
402
|
+
def identify(user_agent)
|
403
|
+
user_agent.downcase!
|
404
|
+
|
405
|
+
if !user_agent.include? KEYWORD
|
406
|
+
return nil
|
407
|
+
end
|
408
|
+
|
409
|
+
result = OperatingSystemDetails.new
|
410
|
+
result.name = 'Windows'
|
411
|
+
result.version = get_version(user_agent)
|
412
|
+
return result
|
413
|
+
end
|
414
|
+
|
415
|
+
end
|
416
|
+
|
417
|
+
|
77
418
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: device_wizard
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- vaughanbrittonsage
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-03-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -62,6 +62,14 @@ extensions: []
|
|
62
62
|
extra_rdoc_files: []
|
63
63
|
files:
|
64
64
|
- ".gitignore"
|
65
|
+
- ".idea/.name"
|
66
|
+
- ".idea/.rakeTasks"
|
67
|
+
- ".idea/device_wizard.iml"
|
68
|
+
- ".idea/encodings.xml"
|
69
|
+
- ".idea/misc.xml"
|
70
|
+
- ".idea/modules.xml"
|
71
|
+
- ".idea/vcs.xml"
|
72
|
+
- ".idea/workspace.xml"
|
65
73
|
- ".rspec"
|
66
74
|
- CODE_OF_CONDUCT.md
|
67
75
|
- Gemfile
|