objcthin 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: c360b06375bb80a241828abefb4b4bdf143c966f
4
+ data.tar.gz: 7f4d59b11cb389a8ecb34adf38dbfe2378ccdc10
5
+ SHA512:
6
+ metadata.gz: 5fa0eec2c0e455f68f3ac9b9ac451ceed6e8223afdd5452ae9f7fe6c4c6577cdaada035c74d9aeb716cd8c6b5a7337335142bb52ed855cd026d10a09018f2d76
7
+ data.tar.gz: 90085eb1fe95d8e2d4878b58ef1197239f62c4472467da6a78023df60936a1c6ff513f5ae5e12952cf47049d9d42416e942ac37ad63a7887700986e08c7b39ac
data/.gitignore ADDED
@@ -0,0 +1,9 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
data/.idea/misc.xml ADDED
@@ -0,0 +1,4 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectRootManager" version="2" project-jdk-name="rbenv: 2.4.0" project-jdk-type="RUBY_SDK" />
4
+ </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/objcthin.iml" filepath="$PROJECT_DIR$/.idea/objcthin.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
@@ -0,0 +1,17 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="RUBY_MODULE" version="4">
3
+ <component name="ModuleRunConfigurationManager">
4
+ <shared />
5
+ <local />
6
+ </component>
7
+ <component name="NewModuleRootManager">
8
+ <content url="file://$MODULE_DIR$" />
9
+ <orderEntry type="inheritedJdk" />
10
+ <orderEntry type="sourceFolder" forTests="false" />
11
+ <orderEntry type="library" scope="PROVIDED" name="bundler (v1.15.4, rbenv: 2.4.0) [gem]" level="application" />
12
+ <orderEntry type="library" scope="PROVIDED" name="minitest (v5.10.3, rbenv: 2.4.0) [gem]" level="application" />
13
+ <orderEntry type="library" scope="PROVIDED" name="rainbow (v2.2.2, rbenv: 2.4.0) [gem]" level="application" />
14
+ <orderEntry type="library" scope="PROVIDED" name="rake (v10.5.0, rbenv: 2.4.0) [gem]" level="application" />
15
+ <orderEntry type="library" scope="PROVIDED" name="thor (v0.20.0, rbenv: 2.4.0) [gem]" level="application" />
16
+ </component>
17
+ </module>
data/.idea/vcs.xml ADDED
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+ </component>
6
+ </project>
@@ -0,0 +1,479 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ChangeListManager">
4
+ <list default="true" id="69d66805-a1ec-48e6-b641-a43f752f569e" name="Default" comment="">
5
+ <change type="MODIFICATION" beforePath="$PROJECT_DIR$/Rakefile" afterPath="$PROJECT_DIR$/Rakefile" />
6
+ <change type="MODIFICATION" beforePath="$PROJECT_DIR$/objcthin.gemspec" afterPath="$PROJECT_DIR$/objcthin.gemspec" />
7
+ </list>
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="FileEditorManager">
16
+ <leaf>
17
+ <file leaf-file-name="objcthin.gemspec" pinned="false" current-in-tab="false">
18
+ <entry file="file://$PROJECT_DIR$/objcthin.gemspec">
19
+ <provider selected="true" editor-type-id="text-editor">
20
+ <state relative-caret-position="237">
21
+ <caret line="19" column="63" lean-forward="true" selection-start-line="19" selection-start-column="63" selection-end-line="19" selection-end-column="63" />
22
+ <folding />
23
+ </state>
24
+ </provider>
25
+ </entry>
26
+ </file>
27
+ <file leaf-file-name="Rakefile" pinned="false" current-in-tab="true">
28
+ <entry file="file://$PROJECT_DIR$/Rakefile">
29
+ <provider selected="true" editor-type-id="text-editor">
30
+ <state relative-caret-position="240">
31
+ <caret line="16" column="0" lean-forward="true" selection-start-line="16" selection-start-column="0" selection-end-line="16" selection-end-column="0" />
32
+ <folding />
33
+ </state>
34
+ </provider>
35
+ </entry>
36
+ </file>
37
+ <file leaf-file-name="objcthin.rb" pinned="false" current-in-tab="false">
38
+ <entry file="file://$PROJECT_DIR$/lib/objcthin.rb">
39
+ <provider selected="true" editor-type-id="text-editor">
40
+ <state relative-caret-position="369">
41
+ <caret line="99" column="24" lean-forward="true" selection-start-line="99" selection-start-column="24" selection-end-line="99" selection-end-column="24" />
42
+ <folding />
43
+ </state>
44
+ </provider>
45
+ </entry>
46
+ </file>
47
+ <file leaf-file-name="rainbow.rb" pinned="false" current-in-tab="false">
48
+ <entry file="file://$USER_HOME$/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/rainbow-2.2.2/lib/rainbow.rb">
49
+ <provider selected="true" editor-type-id="text-editor">
50
+ <state relative-caret-position="0">
51
+ <caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
52
+ <folding />
53
+ </state>
54
+ </provider>
55
+ </entry>
56
+ </file>
57
+ <file leaf-file-name="pathname.rb" pinned="false" current-in-tab="false">
58
+ <entry file="file://$USER_HOME$/.rbenv/versions/2.4.0/lib/ruby/2.4.0/pathname.rb">
59
+ <provider selected="true" editor-type-id="text-editor">
60
+ <state relative-caret-position="416">
61
+ <caret line="568" column="6" lean-forward="false" selection-start-line="568" selection-start-column="6" selection-end-line="568" selection-end-column="6" />
62
+ <folding />
63
+ </state>
64
+ </provider>
65
+ </entry>
66
+ </file>
67
+ <file leaf-file-name="objcthin" pinned="false" current-in-tab="false">
68
+ <entry file="file://$PROJECT_DIR$/exe/objcthin">
69
+ <provider selected="true" editor-type-id="text-editor">
70
+ <state relative-caret-position="75">
71
+ <caret line="5" column="21" lean-forward="false" selection-start-line="5" selection-start-column="21" selection-end-line="5" selection-end-column="21" />
72
+ <folding />
73
+ </state>
74
+ </provider>
75
+ </entry>
76
+ </file>
77
+ </leaf>
78
+ </component>
79
+ <component name="Git.Settings">
80
+ <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
81
+ </component>
82
+ <component name="IdeDocumentHistory">
83
+ <option name="CHANGED_PATHS">
84
+ <list>
85
+ <option value="$PROJECT_DIR$/exe/objcthin" />
86
+ <option value="$PROJECT_DIR$/lib/objcthin.rb" />
87
+ <option value="$PROJECT_DIR$/Rakefile" />
88
+ <option value="$PROJECT_DIR$/objcthin.gemspec" />
89
+ </list>
90
+ </option>
91
+ </component>
92
+ <component name="JsBuildToolGruntFileManager" detection-done="true" sorting="DEFINITION_ORDER" />
93
+ <component name="JsBuildToolPackageJson" detection-done="true" sorting="DEFINITION_ORDER" />
94
+ <component name="JsGulpfileManager">
95
+ <detection-done>true</detection-done>
96
+ <sorting>DEFINITION_ORDER</sorting>
97
+ </component>
98
+ <component name="ProjectFrameBounds">
99
+ <option name="x" value="-1" />
100
+ <option name="y" value="23" />
101
+ <option name="width" value="1280" />
102
+ <option name="height" value="745" />
103
+ </component>
104
+ <component name="ProjectLevelVcsManager" settingsEditedManually="true" />
105
+ <component name="ProjectView">
106
+ <navigator currentView="ProjectPane" proportions="" version="1">
107
+ <flattenPackages />
108
+ <showMembers />
109
+ <showModules />
110
+ <showLibraryContents />
111
+ <hideEmptyPackages />
112
+ <abbreviatePackageNames />
113
+ <autoscrollToSource />
114
+ <autoscrollFromSource />
115
+ <sortByType />
116
+ <manualOrder />
117
+ <foldersAlwaysOnTop value="true" />
118
+ </navigator>
119
+ <panes>
120
+ <pane id="ProjectPane">
121
+ <subPane>
122
+ <PATH>
123
+ <PATH_ELEMENT>
124
+ <option name="myItemId" value="objcthin" />
125
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
126
+ </PATH_ELEMENT>
127
+ <PATH_ELEMENT>
128
+ <option name="myItemId" value="objcthin" />
129
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
130
+ </PATH_ELEMENT>
131
+ </PATH>
132
+ <PATH>
133
+ <PATH_ELEMENT>
134
+ <option name="myItemId" value="objcthin" />
135
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
136
+ </PATH_ELEMENT>
137
+ <PATH_ELEMENT>
138
+ <option name="myItemId" value="objcthin" />
139
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
140
+ </PATH_ELEMENT>
141
+ <PATH_ELEMENT>
142
+ <option name="myItemId" value="lib" />
143
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
144
+ </PATH_ELEMENT>
145
+ </PATH>
146
+ <PATH>
147
+ <PATH_ELEMENT>
148
+ <option name="myItemId" value="objcthin" />
149
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
150
+ </PATH_ELEMENT>
151
+ <PATH_ELEMENT>
152
+ <option name="myItemId" value="objcthin" />
153
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
154
+ </PATH_ELEMENT>
155
+ <PATH_ELEMENT>
156
+ <option name="myItemId" value="lib" />
157
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
158
+ </PATH_ELEMENT>
159
+ <PATH_ELEMENT>
160
+ <option name="myItemId" value="objcthin" />
161
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
162
+ </PATH_ELEMENT>
163
+ </PATH>
164
+ <PATH>
165
+ <PATH_ELEMENT>
166
+ <option name="myItemId" value="objcthin" />
167
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
168
+ </PATH_ELEMENT>
169
+ <PATH_ELEMENT>
170
+ <option name="myItemId" value="objcthin" />
171
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
172
+ </PATH_ELEMENT>
173
+ <PATH_ELEMENT>
174
+ <option name="myItemId" value="exe" />
175
+ <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
176
+ </PATH_ELEMENT>
177
+ </PATH>
178
+ </subPane>
179
+ </pane>
180
+ <pane id="Scope" />
181
+ <pane id="Scratches" />
182
+ </panes>
183
+ </component>
184
+ <component name="PropertiesComponent">
185
+ <property name="WebServerToolWindowFactoryState" value="false" />
186
+ </component>
187
+ <component name="RunDashboard">
188
+ <option name="ruleStates">
189
+ <list>
190
+ <RuleState>
191
+ <option name="name" value="ConfigurationTypeDashboardGroupingRule" />
192
+ </RuleState>
193
+ <RuleState>
194
+ <option name="name" value="StatusDashboardGroupingRule" />
195
+ </RuleState>
196
+ </list>
197
+ </option>
198
+ </component>
199
+ <component name="RunManager">
200
+ <configuration default="true" type="CucumberRunConfigurationType" factoryName="Cucumber">
201
+ <predefined_log_file id="RUBY_CUCUMBER" enabled="true" />
202
+ <module name="" />
203
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
204
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
205
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
206
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
207
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
208
+ <envs />
209
+ <EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
210
+ <EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
211
+ <EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
212
+ <COVERAGE_PATTERN ENABLED="true">
213
+ <PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
214
+ </COVERAGE_PATTERN>
215
+ </EXTENSION>
216
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="**/*.feature" />
217
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
218
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
219
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
220
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_TAGS_FILTER" VALUE="" />
221
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_NAME_FILTER" VALUE="" />
222
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="CUCUMBER_ARGS" VALUE="--color -r features" />
223
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_VERSION" VALUE="" />
224
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="FULL_BACKTRACE" VALUE="false" />
225
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="VERBOSE_OPTION" VALUE="false" />
226
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
227
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
228
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
229
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="CUCUMBER_RUNNER_PATH" VALUE="" />
230
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="USE_CUSTOM_RUNNER" VALUE="false" />
231
+ <CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SETTINGS_VERSION" VALUE="2" />
232
+ <method />
233
+ </configuration>
234
+ <configuration default="true" type="JavaScriptTestRunnerJest" factoryName="Jest">
235
+ <node-interpreter value="project" />
236
+ <working-dir value="" />
237
+ <envs />
238
+ <scope-kind value="ALL" />
239
+ <method />
240
+ </configuration>
241
+ <configuration default="true" type="JavaScriptTestRunnerProtractor" factoryName="Protractor">
242
+ <config-file value="" />
243
+ <node-interpreter value="project" />
244
+ <envs />
245
+ <method />
246
+ </configuration>
247
+ <configuration default="true" type="JavascriptDebugType" factoryName="JavaScript Debug">
248
+ <method />
249
+ </configuration>
250
+ <configuration default="true" type="RSpecRunConfigurationType" factoryName="RSpec">
251
+ <predefined_log_file id="RUBY_RSPEC" enabled="true" />
252
+ <module name="" />
253
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
254
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
255
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
256
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
257
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
258
+ <envs />
259
+ <EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
260
+ <EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
261
+ <EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
262
+ <COVERAGE_PATTERN ENABLED="true">
263
+ <PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
264
+ </COVERAGE_PATTERN>
265
+ </EXTENSION>
266
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
267
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
268
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_RUNNER_PATH" VALUE="" />
269
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="**/*_spec.rb" />
270
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_EXAMPLE_NAME" VALUE="" />
271
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
272
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_ARGS" VALUE="" />
273
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_VERSION" VALUE="" />
274
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="USE_CUSTOM_SPEC_RUNNER" VALUE="false" />
275
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
276
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
277
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
278
+ <RSPEC_RUN_CONFIG_SETTINGS_ID NAME="FULL_BACKTRACE" VALUE="false" />
279
+ <method />
280
+ </configuration>
281
+ <configuration default="true" type="RubyRunConfigurationType" factoryName="Ruby">
282
+ <module name="" />
283
+ <RUBY_RUN_CONFIG NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
284
+ <RUBY_RUN_CONFIG NAME="WORK DIR" VALUE="" />
285
+ <RUBY_RUN_CONFIG NAME="SHOULD_USE_SDK" VALUE="false" />
286
+ <RUBY_RUN_CONFIG NAME="ALTERN_SDK_NAME" VALUE="" />
287
+ <RUBY_RUN_CONFIG NAME="myPassParentEnvs" VALUE="true" />
288
+ <envs />
289
+ <EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
290
+ <EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
291
+ <EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
292
+ <COVERAGE_PATTERN ENABLED="true">
293
+ <PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
294
+ </COVERAGE_PATTERN>
295
+ </EXTENSION>
296
+ <RUBY_RUN_CONFIG NAME="SCRIPT_PATH" VALUE="" />
297
+ <RUBY_RUN_CONFIG NAME="SCRIPT_ARGS" VALUE="" />
298
+ <method />
299
+ </configuration>
300
+ <configuration default="true" type="TestUnitRunConfigurationType" factoryName="Test::Unit/Shoulda/Minitest">
301
+ <predefined_log_file id="RUBY_TESTUNIT" enabled="true" />
302
+ <module name="" />
303
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
304
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
305
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
306
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
307
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
308
+ <envs />
309
+ <EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
310
+ <EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
311
+ <EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
312
+ <COVERAGE_PATTERN ENABLED="true">
313
+ <PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
314
+ </COVERAGE_PATTERN>
315
+ </EXTENSION>
316
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
317
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
318
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="" />
319
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_METHOD_NAME" VALUE="" />
320
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
321
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
322
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
323
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
324
+ <RTEST_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_OPTIONS" VALUE="" />
325
+ <method />
326
+ </configuration>
327
+ <configuration default="true" type="js.build_tools.gulp" factoryName="Gulp.js">
328
+ <method />
329
+ </configuration>
330
+ <configuration default="true" type="js.build_tools.npm" factoryName="npm">
331
+ <command value="run" />
332
+ <scripts />
333
+ <node-interpreter value="project" />
334
+ <envs />
335
+ <method />
336
+ </configuration>
337
+ </component>
338
+ <component name="ShelveChangesManager" show_recycled="false">
339
+ <option name="remove_strategy" value="false" />
340
+ </component>
341
+ <component name="SpringUtil" SPRING_PRE_LOADER_OPTION="true" />
342
+ <component name="TaskManager">
343
+ <task active="true" id="Default" summary="Default task">
344
+ <changelist id="69d66805-a1ec-48e6-b641-a43f752f569e" name="Default" comment="" />
345
+ <created>1508233449256</created>
346
+ <option name="number" value="Default" />
347
+ <option name="presentableId" value="Default" />
348
+ <updated>1508233449256</updated>
349
+ <workItem from="1508233450613" duration="13089000" />
350
+ </task>
351
+ <servers />
352
+ </component>
353
+ <component name="TimeTrackingManager">
354
+ <option name="totallyTimeSpent" value="13089000" />
355
+ </component>
356
+ <component name="ToolWindowManager">
357
+ <frame x="-1" y="23" width="1280" height="745" extended-state="6" />
358
+ <editor active="true" />
359
+ <layout>
360
+ <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
361
+ <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" />
362
+ <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="-1" side_tool="true" content_ui="tabs" />
363
+ <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="-1" side_tool="false" content_ui="tabs" />
364
+ <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="-1" side_tool="false" content_ui="tabs" />
365
+ <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.32905984" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
366
+ <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" />
367
+ <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="-1" side_tool="false" content_ui="tabs" />
368
+ <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="-1" side_tool="true" content_ui="tabs" />
369
+ <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" />
370
+ <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" />
371
+ <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" />
372
+ <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" />
373
+ <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" />
374
+ <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" />
375
+ <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" />
376
+ <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" />
377
+ </layout>
378
+ </component>
379
+ <component name="TypeScriptGeneratedFilesManager">
380
+ <option name="processedProjectFiles" value="true" />
381
+ </component>
382
+ <component name="VcsContentAnnotationSettings">
383
+ <option name="myLimit" value="2678400000" />
384
+ </component>
385
+ <component name="XDebuggerManager">
386
+ <breakpoint-manager />
387
+ <watches-manager />
388
+ </component>
389
+ <component name="editorHistoryManager">
390
+ <entry file="file://$PROJECT_DIR$/exe/objcthin">
391
+ <provider selected="true" editor-type-id="text-editor">
392
+ <state relative-caret-position="75">
393
+ <caret line="5" column="21" lean-forward="false" selection-start-line="5" selection-start-column="21" selection-end-line="5" selection-end-column="21" />
394
+ <folding />
395
+ </state>
396
+ </provider>
397
+ </entry>
398
+ <entry file="file://$USER_HOME$/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/thor-0.20.0/lib/thor.rb">
399
+ <provider selected="true" editor-type-id="text-editor">
400
+ <state relative-caret-position="215">
401
+ <caret line="335" column="7" lean-forward="true" selection-start-line="335" selection-start-column="7" selection-end-line="335" selection-end-column="7" />
402
+ <folding />
403
+ </state>
404
+ </provider>
405
+ </entry>
406
+ <entry file="file://$USER_HOME$/.rbenv/versions/2.4.0/lib/ruby/2.4.0/pathname.rb">
407
+ <provider selected="true" editor-type-id="text-editor">
408
+ <state relative-caret-position="416">
409
+ <caret line="568" column="6" lean-forward="false" selection-start-line="568" selection-start-column="6" selection-end-line="568" selection-end-column="6" />
410
+ <folding />
411
+ </state>
412
+ </provider>
413
+ </entry>
414
+ <entry file="file://$APPLICATION_HOME_DIR$/rubystubs24/pathname.rb">
415
+ <provider selected="true" editor-type-id="text-editor">
416
+ <state relative-caret-position="153">
417
+ <caret line="273" column="38" lean-forward="false" selection-start-line="273" selection-start-column="38" selection-end-line="273" selection-end-column="38" />
418
+ <folding />
419
+ </state>
420
+ </provider>
421
+ </entry>
422
+ <entry file="file://$USER_HOME$/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/rainbow-2.2.2/lib/rainbow.rb">
423
+ <provider selected="true" editor-type-id="text-editor">
424
+ <state relative-caret-position="0">
425
+ <caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
426
+ <folding />
427
+ </state>
428
+ </provider>
429
+ </entry>
430
+ <entry file="file://$APPLICATION_HOME_DIR$/rubystubs24/kernel.rb">
431
+ <provider selected="true" editor-type-id="text-editor">
432
+ <state relative-caret-position="372">
433
+ <caret line="595" column="17" lean-forward="true" selection-start-line="595" selection-start-column="17" selection-end-line="595" selection-end-column="17" />
434
+ <folding />
435
+ </state>
436
+ </provider>
437
+ </entry>
438
+ <entry file="file://$APPLICATION_HOME_DIR$/rubystubs24/regexp.rb">
439
+ <provider selected="true" editor-type-id="text-editor">
440
+ <state relative-caret-position="371">
441
+ <caret line="971" column="8" lean-forward="false" selection-start-line="971" selection-start-column="8" selection-end-line="971" selection-end-column="8" />
442
+ <folding />
443
+ </state>
444
+ </provider>
445
+ </entry>
446
+ <entry file="file://$APPLICATION_HOME_DIR$/rubystubs24/hash.rb">
447
+ <provider selected="true" editor-type-id="text-editor">
448
+ <state relative-caret-position="148">
449
+ <caret line="839" column="8" lean-forward="false" selection-start-line="839" selection-start-column="8" selection-end-line="839" selection-end-column="8" />
450
+ <folding />
451
+ </state>
452
+ </provider>
453
+ </entry>
454
+ <entry file="file://$PROJECT_DIR$/lib/objcthin.rb">
455
+ <provider selected="true" editor-type-id="text-editor">
456
+ <state relative-caret-position="369">
457
+ <caret line="99" column="24" lean-forward="true" selection-start-line="99" selection-start-column="24" selection-end-line="99" selection-end-column="24" />
458
+ <folding />
459
+ </state>
460
+ </provider>
461
+ </entry>
462
+ <entry file="file://$PROJECT_DIR$/objcthin.gemspec">
463
+ <provider selected="true" editor-type-id="text-editor">
464
+ <state relative-caret-position="237">
465
+ <caret line="19" column="63" lean-forward="true" selection-start-line="19" selection-start-column="63" selection-end-line="19" selection-end-column="63" />
466
+ <folding />
467
+ </state>
468
+ </provider>
469
+ </entry>
470
+ <entry file="file://$PROJECT_DIR$/Rakefile">
471
+ <provider selected="true" editor-type-id="text-editor">
472
+ <state relative-caret-position="240">
473
+ <caret line="16" column="0" lean-forward="true" selection-start-line="16" selection-start-column="0" selection-end-line="16" selection-end-column="0" />
474
+ <folding />
475
+ </state>
476
+ </provider>
477
+ </entry>
478
+ </component>
479
+ </project>
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 2.4.0
5
+ before_install: gem install bundler -v 1.15.4
@@ -0,0 +1,74 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at jianming.gu@ele.me. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [http://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: http://contributor-covenant.org
74
+ [version]: http://contributor-covenant.org/version/1/4/
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ source "https://rubygems.org"
2
+
3
+ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
+
5
+ # Specify your gem's dependencies in objcthin.gemspec
6
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2017 顾建明
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,43 @@
1
+ # Objcthin
2
+
3
+ Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/objcthin`. To experiment with that code, run `bin/console` for an interactive prompt.
4
+
5
+ TODO: Delete this and the text above, and describe your gem
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ ```ruby
12
+ gem 'objcthin'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install objcthin
22
+
23
+ ## Usage
24
+
25
+ TODO: Write usage instructions here
26
+
27
+ ## Development
28
+
29
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
+
31
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
32
+
33
+ ## Contributing
34
+
35
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/objcthin. 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
+
37
+ ## License
38
+
39
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
40
+
41
+ ## Code of Conduct
42
+
43
+ Everyone interacting in the Objcthin project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/objcthin/blob/master/CODE_OF_CONDUCT.md).
data/Rakefile ADDED
@@ -0,0 +1,22 @@
1
+ require "bundler/gem_tasks"
2
+ require "rake/testtask"
3
+
4
+ Rake::TestTask.new(:test) do |t|
5
+ t.libs << "test"
6
+ t.libs << "lib"
7
+ t.test_files = FileList["test/**/*_test.rb"]
8
+ end
9
+
10
+ task :install do |t, args|
11
+ system 'gem build objcthin.gemspec'
12
+ path = Dir.glob('*.gem').last
13
+ system "gem install -l #{path}"
14
+ FileUtils.rm Dir.glob('*.gem')
15
+ puts 'completed'
16
+ end
17
+
18
+ task :publish do |t, args|
19
+ system 'gem build objcthin.gemspec'
20
+ path = Dir.glob('*.gem').last
21
+ system 'gem push #{path}'
22
+ end
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "objcthin"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
data/exe/objcthin ADDED
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "objcthin"
4
+
5
+
6
+ Objcthin::Command.start
@@ -0,0 +1,3 @@
1
+ module Objcthin
2
+ VERSION = "0.1.0"
3
+ end
data/lib/objcthin.rb ADDED
@@ -0,0 +1,161 @@
1
+ require "objcthin/version"
2
+ require 'thor'
3
+ require 'rainbow'
4
+ require 'pathname'
5
+
6
+ module Objcthin
7
+ class Command < Thor
8
+ desc 'findsel','find unused method sel'
9
+ def findsel(path)
10
+ Imp::Objc.find_unused_sel(path)
11
+ end
12
+
13
+ desc 'findclass', 'find unused class list'
14
+ def findclass(path)
15
+ Imp::Objc.find_unused_class(path)
16
+ end
17
+
18
+ desc'version','print version'
19
+ def version
20
+ puts Rainbow(Objcthin::VERSION).green
21
+ end
22
+ end
23
+ end
24
+
25
+ module Imp
26
+ class Objc
27
+ def self.find_unused_sel(path)
28
+ check_file_type(path)
29
+ all_sels = find_impl_methods(path)
30
+ used_sel = reference_selectors(path)
31
+
32
+ unused_sel = []
33
+
34
+ all_sels.each do |sel,class_and_sels|
35
+ unless used_sel.include?(sel)
36
+ unused_sel += class_and_sels
37
+ end
38
+ end
39
+
40
+ puts Rainbow('below selector is unused:\n').red
41
+
42
+ puts unused_sel
43
+ end
44
+
45
+ def self.find_unused_class(path)
46
+ check_file_type(path)
47
+ end
48
+
49
+ def self.check_file_type(path)
50
+ pathname = Pathname.new(path)
51
+ unless pathname.exist?
52
+ raise "#{path} not exit!"
53
+ end
54
+
55
+ cmd = "/usr/bin/file -b #{path}"
56
+ output = `#{cmd}`
57
+
58
+ unless output.include?('Mach-O')
59
+ raise 'input file not mach-o file type'
60
+ end
61
+ puts Rainbow('will begin process...').green
62
+ pathname
63
+ end
64
+
65
+ def self.find_impl_methods(path)
66
+
67
+ app = %w[1 2]
68
+
69
+ apple_protocols = [
70
+ 'tableView:canEditRowAtIndexPath:',
71
+ 'commitEditingStyle:forRowAtIndexPath:',
72
+ 'tableView:viewForHeaderInSection:',
73
+ 'tableView:cellForRowAtIndexPath:',
74
+ 'tableView:canPerformAction:forRowAtIndexPath:withSender:',
75
+ 'tableView:performAction:forRowAtIndexPath:withSender:',
76
+ 'tableView:accessoryButtonTappedForRowWithIndexPath:',
77
+ 'tableView:willDisplayCell:forRowAtIndexPath:',
78
+ 'tableView:commitEditingStyle:forRowAtIndexPath:',
79
+ 'tableView:didEndDisplayingCell:forRowAtIndexPath:',
80
+ 'tableView:didEndDisplayingHeaderView:forSection:',
81
+ 'tableView:heightForFooterInSection:',
82
+ 'tableView:shouldHighlightRowAtIndexPath:',
83
+ 'tableView:shouldShowMenuForRowAtIndexPath:',
84
+ 'tableView:viewForFooterInSection:',
85
+ 'tableView:willDisplayHeaderView:forSection:',
86
+ 'tableView:willSelectRowAtIndexPath:',
87
+ 'willMoveToSuperview:',
88
+ 'numberOfSectionsInTableView:',
89
+ 'actionSheet:willDismissWithButtonIndex:',
90
+ 'gestureRecognizer:shouldReceiveTouch:',
91
+ 'gestureRecognizer:shouldRecognizeSimultaneouslyWithGestureRecognizer:',
92
+ 'gestureRecognizer:shouldReceiveTouch:',
93
+ 'imagePickerController:didFinishPickingMediaWithInfo:',
94
+ 'imagePickerControllerDidCancel:',
95
+ 'animateTransition:',
96
+ 'animationControllerForDismissedController:',
97
+ 'animationControllerForPresentedController:presentingController:sourceController:',
98
+ 'navigationController:animationControllerForOperation:fromViewController:toViewController:',
99
+ 'navigationController:interactionControllerForAnimationController:',
100
+ 'alertView:didDismissWithButtonIndex:',
101
+ 'URLSession:didBecomeInvalidWithError:',
102
+ 'setDownloadTaskDidResumeBlock:',
103
+ 'tabBarController:didSelectViewController:',
104
+ 'tabBarController:shouldSelectViewController:',
105
+ 'applicationDidReceiveMemoryWarning:',
106
+ 'application:didRegisterForRemoteNotificationsWithDeviceToken:',
107
+ 'application:didFailToRegisterForRemoteNotificationsWithError:',
108
+ 'application:didReceiveRemoteNotification:fetchCompletionHandler:',
109
+ 'application:didRegisterUserNotificationSettings:',
110
+ 'application:performActionForShortcutItem:completionHandler:',
111
+ 'application:continueUserActivity:restorationHandler:'].freeze
112
+
113
+ # imp -[class sel]
114
+ sub_patten = /[+|-]\[.+\s(.+)\]/
115
+ patten = /\s*imp\s*(#{sub_patten})/
116
+ sel_set_patten = /set[A-Z].*:$/
117
+ sel_get_patten = /is[A-Z].*/
118
+
119
+ output = `/usr/bin/otool -oV #{path}`
120
+
121
+ imp = {}
122
+
123
+ output.each_line do |line|
124
+ patten.match(line) do |m|
125
+ sub = sub_patten.match(m[0]) do |subm|
126
+ class_and_sel = subm[0]
127
+ sel = subm[1]
128
+
129
+ next if sel.start_with?('.')
130
+ next if apple_protocols.include?(sel)
131
+ next if sel_set_patten.match?(sel)
132
+ next if sel_get_patten.match?(sel)
133
+
134
+ if imp.has_key?(sel)
135
+ imp[sel] << class_and_sel
136
+ else
137
+ imp[sel] = [class_and_sel]
138
+ end
139
+ end
140
+ end
141
+ end
142
+
143
+ imp.sort
144
+ end
145
+
146
+ def self.reference_selectors(path)
147
+ patten = /__TEXT:__objc_methname:(.+)/
148
+ output = `/usr/bin/otool -v -s __DATA __objc_selrefs #{path}`
149
+
150
+ sels = []
151
+ output.each_line do |line|
152
+ patten.match(line) do |m|
153
+ sels << m[1]
154
+ end
155
+ end
156
+
157
+ sels
158
+ end
159
+
160
+ end
161
+ end
data/objcthin.gemspec ADDED
@@ -0,0 +1,39 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require "objcthin/version"
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "objcthin"
8
+ spec.version = Objcthin::VERSION
9
+ spec.authors = ["jamy_gu"]
10
+ spec.email = ["gg.jamy@163.com"]
11
+
12
+ spec.summary = %q{find unused method and class with mach-o file.}
13
+ spec.description = %q{find unused method and class with mach-o file.}
14
+ spec.homepage = "https://github.com/svenJamy/objcthin"
15
+ spec.license = "MIT"
16
+
17
+ # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
18
+ # to allow pushing to a single host or delete this section to allow pushing to any host.
19
+ if spec.respond_to?(:metadata)
20
+ spec.metadata["allowed_push_host"] = "https://rubygems.org"
21
+ else
22
+ raise "RubyGems 2.0 or newer is required to protect against " \
23
+ "public gem pushes."
24
+ end
25
+
26
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
27
+ f.match(%r{^(test|spec|features)/})
28
+ end
29
+ spec.bindir = "exe"
30
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
31
+ spec.require_paths = ["lib"]
32
+
33
+ spec.add_runtime_dependency "thor", "~> 0.19"
34
+ spec.add_runtime_dependency "rainbow", "~> 2.2"
35
+
36
+ spec.add_development_dependency "bundler", "~> 1.15"
37
+ spec.add_development_dependency "rake", "~> 10.0"
38
+ spec.add_development_dependency "minitest", "~> 5.0"
39
+ end
metadata ADDED
@@ -0,0 +1,135 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: objcthin
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - jamy_gu
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2017-10-18 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: thor
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '0.19'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '0.19'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rainbow
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '2.2'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '2.2'
41
+ - !ruby/object:Gem::Dependency
42
+ name: bundler
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '1.15'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '1.15'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '10.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '10.0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: minitest
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '5.0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '5.0'
83
+ description: find unused method and class with mach-o file.
84
+ email:
85
+ - gg.jamy@163.com
86
+ executables:
87
+ - objcthin
88
+ extensions: []
89
+ extra_rdoc_files: []
90
+ files:
91
+ - ".gitignore"
92
+ - ".idea/misc.xml"
93
+ - ".idea/modules.xml"
94
+ - ".idea/objcthin.iml"
95
+ - ".idea/vcs.xml"
96
+ - ".idea/workspace.xml"
97
+ - ".travis.yml"
98
+ - CODE_OF_CONDUCT.md
99
+ - Gemfile
100
+ - LICENSE.txt
101
+ - README.md
102
+ - Rakefile
103
+ - bin/console
104
+ - bin/setup
105
+ - exe/objcthin
106
+ - lib/objcthin.rb
107
+ - lib/objcthin/version.rb
108
+ - objcthin.gemspec
109
+ homepage: https://github.com/svenJamy/objcthin
110
+ licenses:
111
+ - MIT
112
+ metadata:
113
+ allowed_push_host: https://rubygems.org
114
+ post_install_message:
115
+ rdoc_options: []
116
+ require_paths:
117
+ - lib
118
+ required_ruby_version: !ruby/object:Gem::Requirement
119
+ requirements:
120
+ - - ">="
121
+ - !ruby/object:Gem::Version
122
+ version: '0'
123
+ required_rubygems_version: !ruby/object:Gem::Requirement
124
+ requirements:
125
+ - - ">="
126
+ - !ruby/object:Gem::Version
127
+ version: '0'
128
+ requirements: []
129
+ rubyforge_project:
130
+ rubygems_version: 2.6.8
131
+ signing_key:
132
+ specification_version: 4
133
+ summary: find unused method and class with mach-o file.
134
+ test_files: []
135
+ has_rdoc: