edge_csv 0.0.0 → 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 +4 -4
- data/.gitignore +0 -1
- data/.idea/edge_csv.iml +1 -1
- data/.idea/workspace.xml +36 -368
- data/README.md +17 -15
- data/edge_csv.gemspec +2 -2
- data/lib/edge_csv/version.rb +1 -1
- data/lib/edge_csv.rb +3 -11
- metadata +3 -6
- data/lib/edge_csv/export.rb +0 -35
- data/lib/helpers/export_helpert.rb +0 -22
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c56b6d0e42c941b1a3c4c52c5c7a4b0b03a6cce8
|
4
|
+
data.tar.gz: 5dda2557a1cbe890f5ebce1c38fa5e7ee85d251f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a837b9091e55fb6b141afd6955f5bbf25471e4d89ce11f84adb26d0b5f35f22d082591183f462b74854dad8839c0b253b0c66233683ed76e0f4d6cfa18487ec
|
7
|
+
data.tar.gz: ed3cd6e7f930730974824052ccf7067f41b97bac3504fe1a21116787832f181d654131da878cbf6ac75b102972d7089037ca699b83391b45423008f435c9a1c1
|
data/.gitignore
CHANGED
data/.idea/edge_csv.iml
CHANGED
@@ -17,6 +17,6 @@
|
|
17
17
|
<orderEntry type="inheritedJdk" />
|
18
18
|
<orderEntry type="sourceFolder" forTests="false" />
|
19
19
|
<orderEntry type="library" scope="PROVIDED" name="bundler (v1.13.7, RVM: ruby-2.3.0) [gem]" level="application" />
|
20
|
-
<orderEntry type="library" scope="PROVIDED" name="rake (v10.
|
20
|
+
<orderEntry type="library" scope="PROVIDED" name="rake (v10.4.2, RVM: ruby-2.3.0) [gem]" level="application" />
|
21
21
|
</component>
|
22
22
|
</module>
|
data/.idea/workspace.xml
CHANGED
@@ -1,9 +1,7 @@
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
2
2
|
<project version="4">
|
3
3
|
<component name="ChangeListManager">
|
4
|
-
<list default="true" id="fd515e82-a949-4b98-a4c3-95206c4be8c5" name="Default" comment=""
|
5
|
-
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
|
6
|
-
</list>
|
4
|
+
<list default="true" id="fd515e82-a949-4b98-a4c3-95206c4be8c5" name="Default" comment="" />
|
7
5
|
<ignored path="edge_csv.iws" />
|
8
6
|
<ignored path=".idea/workspace.xml" />
|
9
7
|
<ignored path="$PROJECT_DIR$/.bundle/" />
|
@@ -31,42 +29,32 @@
|
|
31
29
|
<favorites_list name="edge_csv" />
|
32
30
|
</component>
|
33
31
|
<component name="FileEditorManager">
|
34
|
-
<leaf
|
32
|
+
<leaf>
|
35
33
|
<file leaf-file-name="edge_csv.gemspec" pinned="false" current-in-tab="true">
|
36
34
|
<entry file="file://$PROJECT_DIR$/edge_csv.gemspec">
|
37
35
|
<provider selected="true" editor-type-id="text-editor">
|
38
|
-
<state relative-caret-position="
|
39
|
-
<caret line="
|
36
|
+
<state relative-caret-position="80">
|
37
|
+
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
|
40
38
|
<folding />
|
41
39
|
</state>
|
42
40
|
</provider>
|
43
41
|
</entry>
|
44
42
|
</file>
|
45
|
-
<file leaf-file-name="
|
46
|
-
<entry file="file://$PROJECT_DIR$/
|
43
|
+
<file leaf-file-name="console" pinned="false" current-in-tab="false">
|
44
|
+
<entry file="file://$PROJECT_DIR$/bin/console">
|
47
45
|
<provider selected="true" editor-type-id="text-editor">
|
48
|
-
<state relative-caret-position="
|
49
|
-
<caret line="
|
46
|
+
<state relative-caret-position="0">
|
47
|
+
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
50
48
|
<folding />
|
51
49
|
</state>
|
52
50
|
</provider>
|
53
51
|
</entry>
|
54
52
|
</file>
|
55
|
-
<file leaf-file-name="
|
56
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv
|
57
|
-
<provider selected="true" editor-type-id="text-editor">
|
58
|
-
<state relative-caret-position="500">
|
59
|
-
<caret line="25" column="21" selection-start-line="25" selection-start-column="21" selection-end-line="25" selection-end-column="21" />
|
60
|
-
<folding />
|
61
|
-
</state>
|
62
|
-
</provider>
|
63
|
-
</entry>
|
64
|
-
</file>
|
65
|
-
<file leaf-file-name="export_helpert.rb" pinned="false" current-in-tab="false">
|
66
|
-
<entry file="file://$PROJECT_DIR$/lib/helpers/export_helpert.rb">
|
53
|
+
<file leaf-file-name="edge_csv.rb" pinned="false" current-in-tab="false">
|
54
|
+
<entry file="file://$PROJECT_DIR$/lib/edge_csv.rb">
|
67
55
|
<provider selected="true" editor-type-id="text-editor">
|
68
|
-
<state relative-caret-position="
|
69
|
-
<caret line="
|
56
|
+
<state relative-caret-position="80">
|
57
|
+
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
|
70
58
|
<folding />
|
71
59
|
</state>
|
72
60
|
</provider>
|
@@ -80,13 +68,7 @@
|
|
80
68
|
<component name="IdeDocumentHistory">
|
81
69
|
<option name="CHANGED_PATHS">
|
82
70
|
<list>
|
83
|
-
<option value="$PROJECT_DIR$/lib/export.rb" />
|
84
|
-
<option value="$PROJECT_DIR$/lib/edge_csv/import.rb" />
|
85
71
|
<option value="$PROJECT_DIR$/lib/edge_csv.rb" />
|
86
|
-
<option value="$PROJECT_DIR$/.gitignore" />
|
87
|
-
<option value="$PROJECT_DIR$/README.md" />
|
88
|
-
<option value="$PROJECT_DIR$/lib/edge_csv/export.rb" />
|
89
|
-
<option value="$PROJECT_DIR$/lib/helpers/export_helpert.rb" />
|
90
72
|
<option value="$PROJECT_DIR$/edge_csv.gemspec" />
|
91
73
|
</list>
|
92
74
|
</option>
|
@@ -127,6 +109,7 @@
|
|
127
109
|
<foldersAlwaysOnTop value="true" />
|
128
110
|
</navigator>
|
129
111
|
<panes>
|
112
|
+
<pane id="Scratches" />
|
130
113
|
<pane id="ProjectPane">
|
131
114
|
<subPane>
|
132
115
|
<PATH>
|
@@ -163,9 +146,22 @@
|
|
163
146
|
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
164
147
|
</PATH_ELEMENT>
|
165
148
|
</PATH>
|
149
|
+
<PATH>
|
150
|
+
<PATH_ELEMENT>
|
151
|
+
<option name="myItemId" value="edge_csv" />
|
152
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
153
|
+
</PATH_ELEMENT>
|
154
|
+
<PATH_ELEMENT>
|
155
|
+
<option name="myItemId" value="edge_csv" />
|
156
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
157
|
+
</PATH_ELEMENT>
|
158
|
+
<PATH_ELEMENT>
|
159
|
+
<option name="myItemId" value="bin" />
|
160
|
+
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
161
|
+
</PATH_ELEMENT>
|
162
|
+
</PATH>
|
166
163
|
</subPane>
|
167
164
|
</pane>
|
168
|
-
<pane id="Scratches" />
|
169
165
|
<pane id="Scope" />
|
170
166
|
</panes>
|
171
167
|
</component>
|
@@ -174,136 +170,6 @@
|
|
174
170
|
<property name="settings.editor.splitter.proportion" value="0.2" />
|
175
171
|
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
|
176
172
|
<property name="WebServerToolWindowFactoryState" value="false" />
|
177
|
-
<property name="js-jscs-nodeInterpreter" value="/usr/bin/node" />
|
178
|
-
</component>
|
179
|
-
<component name="RecentsManager">
|
180
|
-
<key name="MoveFile.RECENT_KEYS">
|
181
|
-
<recent name="$PROJECT_DIR$/lib/edge_csv" />
|
182
|
-
</key>
|
183
|
-
</component>
|
184
|
-
<component name="RunManager">
|
185
|
-
<configuration default="true" type="BashConfigurationType" factoryName="Bash">
|
186
|
-
<option name="INTERPRETER_OPTIONS" value="" />
|
187
|
-
<option name="INTERPRETER_PATH" value="/bin/bash" />
|
188
|
-
<option name="WORKING_DIRECTORY" value="" />
|
189
|
-
<option name="PARENT_ENVS" value="true" />
|
190
|
-
<option name="SCRIPT_NAME" value="" />
|
191
|
-
<option name="PARAMETERS" value="" />
|
192
|
-
<module name="" />
|
193
|
-
<envs />
|
194
|
-
<method />
|
195
|
-
</configuration>
|
196
|
-
<configuration default="true" type="CucumberRunConfigurationType" factoryName="Cucumber">
|
197
|
-
<predefined_log_file id="RUBY_CUCUMBER" enabled="true" />
|
198
|
-
<module name="" />
|
199
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
200
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
201
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
202
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
203
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
204
|
-
<envs />
|
205
|
-
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
206
|
-
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
207
|
-
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
208
|
-
<COVERAGE_PATTERN ENABLED="true">
|
209
|
-
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
210
|
-
</COVERAGE_PATTERN>
|
211
|
-
</EXTENSION>
|
212
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="**/*.feature" />
|
213
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
|
214
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
|
215
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
|
216
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_TAGS_FILTER" VALUE="" />
|
217
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="TEST_NAME_FILTER" VALUE="" />
|
218
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="CUCUMBER_ARGS" VALUE="--color -r features" />
|
219
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_VERSION" VALUE="" />
|
220
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="FULL_BACKTRACE" VALUE="false" />
|
221
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="VERBOSE_OPTION" VALUE="false" />
|
222
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
|
223
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
|
224
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
|
225
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="CUCUMBER_RUNNER_PATH" VALUE="" />
|
226
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="USE_CUSTOM_RUNNER" VALUE="false" />
|
227
|
-
<CUCUMBER_RUN_CONFIG_SETTINGS_ID NAME="SETTINGS_VERSION" VALUE="2" />
|
228
|
-
<method />
|
229
|
-
</configuration>
|
230
|
-
<configuration default="true" type="JavascriptDebugType" factoryName="JavaScript Debug">
|
231
|
-
<method />
|
232
|
-
</configuration>
|
233
|
-
<configuration default="true" type="RSpecRunConfigurationType" factoryName="RSpec">
|
234
|
-
<predefined_log_file id="RUBY_RSPEC" enabled="true" />
|
235
|
-
<module name="" />
|
236
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
237
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
238
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
239
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
240
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
241
|
-
<envs />
|
242
|
-
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
243
|
-
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
244
|
-
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
245
|
-
<COVERAGE_PATTERN ENABLED="true">
|
246
|
-
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
247
|
-
</COVERAGE_PATTERN>
|
248
|
-
</EXTENSION>
|
249
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
|
250
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
|
251
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_RUNNER_PATH" VALUE="" />
|
252
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="**/*_spec.rb" />
|
253
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_EXAMPLE_NAME" VALUE="" />
|
254
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
|
255
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPEC_ARGS" VALUE="" />
|
256
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_VERSION" VALUE="" />
|
257
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="USE_CUSTOM_SPEC_RUNNER" VALUE="false" />
|
258
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
|
259
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
|
260
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
|
261
|
-
<RSPEC_RUN_CONFIG_SETTINGS_ID NAME="FULL_BACKTRACE" VALUE="false" />
|
262
|
-
<method />
|
263
|
-
</configuration>
|
264
|
-
<configuration default="true" type="TestUnitRunConfigurationType" factoryName="Test::Unit/Shoulda/Minitest">
|
265
|
-
<predefined_log_file id="RUBY_TESTUNIT" enabled="true" />
|
266
|
-
<module name="" />
|
267
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="-e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift)" />
|
268
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
269
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
270
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
271
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
272
|
-
<envs />
|
273
|
-
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="false" />
|
274
|
-
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
275
|
-
<EXTENSION ID="RubyCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" track_test_folders="true" runner="rcov">
|
276
|
-
<COVERAGE_PATTERN ENABLED="true">
|
277
|
-
<PATTERN REGEXPS="/.rvm/" INCLUDED="false" />
|
278
|
-
</COVERAGE_PATTERN>
|
279
|
-
</EXTENSION>
|
280
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TESTS_FOLDER_PATH" VALUE="" />
|
281
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_SCRIPT_PATH" VALUE="" />
|
282
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_FILE_MASK" VALUE="" />
|
283
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_METHOD_NAME" VALUE="" />
|
284
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="TEST_TEST_TYPE" VALUE="TEST_SCRIPT" />
|
285
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="DRB" VALUE="false" />
|
286
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="ZEUS" VALUE="false" />
|
287
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="SPRING" VALUE="false" />
|
288
|
-
<RTEST_RUN_CONFIG_SETTINGS_ID NAME="RUNNER_OPTIONS" VALUE="" />
|
289
|
-
<method />
|
290
|
-
</configuration>
|
291
|
-
<configuration default="true" type="js.build_tools.gulp" factoryName="Gulp.js">
|
292
|
-
<node-interpreter>project</node-interpreter>
|
293
|
-
<node-options />
|
294
|
-
<gulpfile />
|
295
|
-
<tasks />
|
296
|
-
<arguments />
|
297
|
-
<envs />
|
298
|
-
<method />
|
299
|
-
</configuration>
|
300
|
-
<configuration default="true" type="js.build_tools.npm" factoryName="npm">
|
301
|
-
<command value="run-script" />
|
302
|
-
<scripts />
|
303
|
-
<node-interpreter value="project" />
|
304
|
-
<envs />
|
305
|
-
<method />
|
306
|
-
</configuration>
|
307
173
|
</component>
|
308
174
|
<component name="ShelveChangesManager" show_recycled="false">
|
309
175
|
<option name="remove_strategy" value="false" />
|
@@ -315,24 +181,21 @@
|
|
315
181
|
<option name="number" value="Default" />
|
316
182
|
<option name="presentableId" value="Default" />
|
317
183
|
<updated>1484390064424</updated>
|
318
|
-
<workItem from="1484390065775" duration="
|
319
|
-
<workItem from="1484583017767" duration="2648000" />
|
320
|
-
<workItem from="1487696894790" duration="374000" />
|
321
|
-
<workItem from="1487698507949" duration="123000" />
|
184
|
+
<workItem from="1484390065775" duration="1829000" />
|
322
185
|
</task>
|
323
186
|
<servers />
|
324
187
|
</component>
|
325
188
|
<component name="TimeTrackingManager">
|
326
|
-
<option name="totallyTimeSpent" value="
|
189
|
+
<option name="totallyTimeSpent" value="1829000" />
|
327
190
|
</component>
|
328
191
|
<component name="ToolWindowManager">
|
329
192
|
<frame x="65" y="-4" width="1855" height="1084" extended-state="6" />
|
330
193
|
<editor active="false" />
|
331
194
|
<layout>
|
332
|
-
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.
|
195
|
+
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.21503593" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
|
333
196
|
<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" />
|
334
197
|
<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.3174442" sideWeight="0.50193477" order="10" side_tool="true" content_ui="tabs" />
|
335
|
-
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="
|
198
|
+
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.19458264" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
336
199
|
<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.27281946" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
337
200
|
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.2498618" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
338
201
|
<window_info id="Terminal" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.39249492" sideWeight="0.49806523" order="9" side_tool="false" content_ui="tabs" />
|
@@ -349,35 +212,6 @@
|
|
349
212
|
<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" />
|
350
213
|
<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" />
|
351
214
|
</layout>
|
352
|
-
<layout-to-restore>
|
353
|
-
<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" />
|
354
|
-
<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" />
|
355
|
-
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4888438" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
|
356
|
-
<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" />
|
357
|
-
<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" />
|
358
|
-
<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.3174442" sideWeight="0.50193477" order="10" side_tool="true" content_ui="tabs" />
|
359
|
-
<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" />
|
360
|
-
<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.27281946" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
361
|
-
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.3296146" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
362
|
-
<window_info id="Thumbnails" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.3296146" sideWeight="0.5" order="11" side_tool="false" content_ui="tabs" />
|
363
|
-
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.39249492" sideWeight="0.49806523" order="9" side_tool="false" content_ui="tabs" />
|
364
|
-
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.21503593" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
|
365
|
-
<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" />
|
366
|
-
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.19458264" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
367
|
-
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.22008114" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
368
|
-
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.2498618" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
369
|
-
<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" />
|
370
|
-
<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="0" side_tool="true" content_ui="tabs" />
|
371
|
-
<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" />
|
372
|
-
</layout-to-restore>
|
373
|
-
</component>
|
374
|
-
<component name="Vcs.Log.UiProperties">
|
375
|
-
<option name="RECENTLY_FILTERED_USER_GROUPS">
|
376
|
-
<collection />
|
377
|
-
</option>
|
378
|
-
<option name="RECENTLY_FILTERED_BRANCH_GROUPS">
|
379
|
-
<collection />
|
380
|
-
</option>
|
381
215
|
</component>
|
382
216
|
<component name="VcsContentAnnotationSettings">
|
383
217
|
<option name="myLimit" value="2678400000" />
|
@@ -387,138 +221,11 @@
|
|
387
221
|
<watches-manager />
|
388
222
|
</component>
|
389
223
|
<component name="editorHistoryManager">
|
390
|
-
<entry file="file://$PROJECT_DIR$/edge_csv.gemspec">
|
391
|
-
<provider selected="true" editor-type-id="text-editor">
|
392
|
-
<state relative-caret-position="0">
|
393
|
-
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
394
|
-
<folding />
|
395
|
-
</state>
|
396
|
-
</provider>
|
397
|
-
</entry>
|
398
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv.rb">
|
399
|
-
<provider selected="true" editor-type-id="text-editor">
|
400
|
-
<state relative-caret-position="160">
|
401
|
-
<caret line="8" column="22" selection-start-line="8" selection-start-column="22" selection-end-line="8" selection-end-column="22" />
|
402
|
-
<folding />
|
403
|
-
</state>
|
404
|
-
</provider>
|
405
|
-
</entry>
|
406
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/export.rb">
|
407
|
-
<provider selected="true" editor-type-id="text-editor">
|
408
|
-
<state relative-caret-position="500">
|
409
|
-
<caret line="25" column="21" selection-start-line="25" selection-start-column="21" selection-end-line="25" selection-end-column="21" />
|
410
|
-
<folding />
|
411
|
-
</state>
|
412
|
-
</provider>
|
413
|
-
</entry>
|
414
|
-
<entry file="file://$PROJECT_DIR$/lib/helpers/export_helpert.rb">
|
415
|
-
<provider selected="true" editor-type-id="text-editor">
|
416
|
-
<state relative-caret-position="240">
|
417
|
-
<caret line="12" column="7" selection-start-line="10" selection-start-column="4" selection-end-line="12" selection-end-column="7" />
|
418
|
-
<folding />
|
419
|
-
</state>
|
420
|
-
</provider>
|
421
|
-
</entry>
|
422
|
-
<entry file="file://$PROJECT_DIR$/edge_csv.gemspec">
|
423
|
-
<provider selected="true" editor-type-id="text-editor">
|
424
|
-
<state relative-caret-position="260">
|
425
|
-
<caret line="13" column="24" selection-start-line="13" selection-start-column="24" selection-end-line="13" selection-end-column="24" />
|
426
|
-
<folding />
|
427
|
-
</state>
|
428
|
-
</provider>
|
429
|
-
</entry>
|
430
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv.rb">
|
431
|
-
<provider selected="true" editor-type-id="text-editor">
|
432
|
-
<state relative-caret-position="160">
|
433
|
-
<caret line="8" column="22" selection-start-line="8" selection-start-column="22" selection-end-line="8" selection-end-column="22" />
|
434
|
-
<folding />
|
435
|
-
</state>
|
436
|
-
</provider>
|
437
|
-
</entry>
|
438
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/export.rb">
|
439
|
-
<provider selected="true" editor-type-id="text-editor">
|
440
|
-
<state relative-caret-position="0">
|
441
|
-
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
442
|
-
<folding />
|
443
|
-
</state>
|
444
|
-
</provider>
|
445
|
-
</entry>
|
446
|
-
<entry file="file://$PROJECT_DIR$/lib/helpers/export_helpert.rb">
|
447
|
-
<provider selected="true" editor-type-id="text-editor">
|
448
|
-
<state relative-caret-position="240">
|
449
|
-
<caret line="12" column="7" selection-start-line="10" selection-start-column="4" selection-end-line="12" selection-end-column="7" />
|
450
|
-
<folding />
|
451
|
-
</state>
|
452
|
-
</provider>
|
453
|
-
</entry>
|
454
|
-
<entry file="file://$PROJECT_DIR$/edge_csv.gemspec">
|
455
|
-
<provider selected="true" editor-type-id="text-editor">
|
456
|
-
<state relative-caret-position="0">
|
457
|
-
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
458
|
-
<folding />
|
459
|
-
</state>
|
460
|
-
</provider>
|
461
|
-
</entry>
|
462
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv.rb">
|
463
|
-
<provider selected="true" editor-type-id="text-editor">
|
464
|
-
<state relative-caret-position="160">
|
465
|
-
<caret line="8" column="14" selection-start-line="8" selection-start-column="14" selection-end-line="8" selection-end-column="14" />
|
466
|
-
<folding />
|
467
|
-
</state>
|
468
|
-
</provider>
|
469
|
-
</entry>
|
470
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/export.rb">
|
471
|
-
<provider selected="true" editor-type-id="text-editor">
|
472
|
-
<state relative-caret-position="160">
|
473
|
-
<caret line="8" column="38" selection-start-line="8" selection-start-column="38" selection-end-line="8" selection-end-column="38" />
|
474
|
-
<folding />
|
475
|
-
</state>
|
476
|
-
</provider>
|
477
|
-
</entry>
|
478
|
-
<entry file="file://$PROJECT_DIR$/lib/helpers/export_helpert.rb">
|
479
|
-
<provider selected="true" editor-type-id="text-editor">
|
480
|
-
<state relative-caret-position="60">
|
481
|
-
<caret line="3" column="59" selection-start-line="3" selection-start-column="59" selection-end-line="3" selection-end-column="59" />
|
482
|
-
<folding />
|
483
|
-
</state>
|
484
|
-
</provider>
|
485
|
-
</entry>
|
486
|
-
<entry file="file://$PROJECT_DIR$/edge_csv.gemspec">
|
487
|
-
<provider selected="true" editor-type-id="text-editor">
|
488
|
-
<state relative-caret-position="0">
|
489
|
-
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
490
|
-
<folding />
|
491
|
-
</state>
|
492
|
-
</provider>
|
493
|
-
</entry>
|
494
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv.rb">
|
495
|
-
<provider selected="true" editor-type-id="text-editor">
|
496
|
-
<state relative-caret-position="160">
|
497
|
-
<caret line="8" column="14" selection-start-line="8" selection-start-column="14" selection-end-line="8" selection-end-column="14" />
|
498
|
-
<folding />
|
499
|
-
</state>
|
500
|
-
</provider>
|
501
|
-
</entry>
|
502
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/export.rb">
|
503
|
-
<provider selected="true" editor-type-id="text-editor">
|
504
|
-
<state relative-caret-position="160">
|
505
|
-
<caret line="8" column="38" selection-start-line="8" selection-start-column="38" selection-end-line="8" selection-end-column="38" />
|
506
|
-
<folding />
|
507
|
-
</state>
|
508
|
-
</provider>
|
509
|
-
</entry>
|
510
|
-
<entry file="file://$PROJECT_DIR$/lib/helpers/export_helpert.rb">
|
511
|
-
<provider selected="true" editor-type-id="text-editor">
|
512
|
-
<state relative-caret-position="60">
|
513
|
-
<caret line="3" column="59" selection-start-line="3" selection-start-column="59" selection-end-line="3" selection-end-column="59" />
|
514
|
-
<folding />
|
515
|
-
</state>
|
516
|
-
</provider>
|
517
|
-
</entry>
|
518
224
|
<entry file="file://$PROJECT_DIR$/bin/setup">
|
519
225
|
<provider selected="true" editor-type-id="text-editor">
|
520
226
|
<state relative-caret-position="0">
|
521
227
|
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
228
|
+
<folding />
|
522
229
|
</state>
|
523
230
|
</provider>
|
524
231
|
</entry>
|
@@ -526,61 +233,22 @@
|
|
526
233
|
<provider selected="true" editor-type-id="text-editor">
|
527
234
|
<state relative-caret-position="0">
|
528
235
|
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
529
|
-
</state>
|
530
|
-
</provider>
|
531
|
-
</entry>
|
532
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/import.rb" />
|
533
|
-
<entry file="file://$PROJECT_DIR$/edge_csv-0.1.0.gem" />
|
534
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/version.rb">
|
535
|
-
<provider selected="true" editor-type-id="text-editor">
|
536
|
-
<state relative-caret-position="0">
|
537
|
-
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
538
|
-
</state>
|
539
|
-
</provider>
|
540
|
-
</entry>
|
541
|
-
<entry file="file://$PROJECT_DIR$/.gitignore">
|
542
|
-
<provider selected="true" editor-type-id="text-editor">
|
543
|
-
<state relative-caret-position="40">
|
544
|
-
<caret line="2" column="13" selection-start-line="2" selection-start-column="13" selection-end-line="2" selection-end-column="13" />
|
545
|
-
<folding />
|
546
|
-
</state>
|
547
|
-
</provider>
|
548
|
-
</entry>
|
549
|
-
<entry file="file://$PROJECT_DIR$/README.md">
|
550
|
-
<provider selected="true" editor-type-id="text-editor">
|
551
|
-
<state relative-caret-position="249">
|
552
|
-
<caret line="23" column="7" selection-start-line="23" selection-start-column="7" selection-end-line="23" selection-end-column="7" />
|
553
|
-
</state>
|
554
|
-
</provider>
|
555
|
-
</entry>
|
556
|
-
<entry file="file://$PROJECT_DIR$/lib/helpers/export_helpert.rb">
|
557
|
-
<provider selected="true" editor-type-id="text-editor">
|
558
|
-
<state relative-caret-position="240">
|
559
|
-
<caret line="12" column="7" selection-start-line="10" selection-start-column="4" selection-end-line="12" selection-end-column="7" />
|
560
|
-
<folding />
|
561
|
-
</state>
|
562
|
-
</provider>
|
563
|
-
</entry>
|
564
|
-
<entry file="file://$PROJECT_DIR$/lib/edge_csv/export.rb">
|
565
|
-
<provider selected="true" editor-type-id="text-editor">
|
566
|
-
<state relative-caret-position="500">
|
567
|
-
<caret line="25" column="21" selection-start-line="25" selection-start-column="21" selection-end-line="25" selection-end-column="21" />
|
568
236
|
<folding />
|
569
237
|
</state>
|
570
238
|
</provider>
|
571
239
|
</entry>
|
572
240
|
<entry file="file://$PROJECT_DIR$/lib/edge_csv.rb">
|
573
241
|
<provider selected="true" editor-type-id="text-editor">
|
574
|
-
<state relative-caret-position="
|
575
|
-
<caret line="
|
242
|
+
<state relative-caret-position="80">
|
243
|
+
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
|
576
244
|
<folding />
|
577
245
|
</state>
|
578
246
|
</provider>
|
579
247
|
</entry>
|
580
248
|
<entry file="file://$PROJECT_DIR$/edge_csv.gemspec">
|
581
249
|
<provider selected="true" editor-type-id="text-editor">
|
582
|
-
<state relative-caret-position="
|
583
|
-
<caret line="
|
250
|
+
<state relative-caret-position="80">
|
251
|
+
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
|
584
252
|
<folding />
|
585
253
|
</state>
|
586
254
|
</provider>
|
data/README.md
CHANGED
@@ -1,8 +1,10 @@
|
|
1
1
|
# EdgeCsv
|
2
2
|
|
3
|
-
|
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/edge_csv`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
4
|
|
5
|
-
|
5
|
+
TODO: Delete this and the text above, and describe your gem
|
6
|
+
|
7
|
+
## Installation
|
6
8
|
|
7
9
|
Add this line to your application's Gemfile:
|
8
10
|
|
@@ -18,17 +20,17 @@ Or install it yourself as:
|
|
18
20
|
|
19
21
|
$ gem install edge_csv
|
20
22
|
|
21
|
-
##
|
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. 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]/edge_csv.
|
23
36
|
|
24
|
-
```ruby
|
25
|
-
{
|
26
|
-
"subjects": @products,
|
27
|
-
"fileds": %w(price name),
|
28
|
-
"sequince": %w(name price),
|
29
|
-
"headers": false,
|
30
|
-
"header_names": {
|
31
|
-
"name": "Product Name",
|
32
|
-
"price": "Product Price"
|
33
|
-
}
|
34
|
-
}
|
data/edge_csv.gemspec
CHANGED
@@ -6,12 +6,12 @@ require 'edge_csv/version'
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
7
|
spec.name = "edge_csv"
|
8
8
|
spec.version = EdgeCsv::VERSION
|
9
|
-
spec.authors = ["Dmitry Gusev", "Arvid Stahovskiy"
|
9
|
+
spec.authors = ["Dmitry Gusev", "Arvid Stahovskiy"]
|
10
10
|
spec.email = ["dmitriy.gusev@duniceedge.com"]
|
11
11
|
|
12
12
|
spec.summary = %q{A warning so people will logoff and go to bed!.}
|
13
13
|
spec.description = %q{A warning so people will logoff and go to bed!}
|
14
|
-
spec.homepage = "
|
14
|
+
spec.homepage = ""
|
15
15
|
|
16
16
|
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
17
17
|
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
data/lib/edge_csv/version.rb
CHANGED
data/lib/edge_csv.rb
CHANGED
@@ -1,13 +1,5 @@
|
|
1
|
-
require
|
2
|
-
class EdgeCsv
|
3
|
-
|
4
|
-
def self.import
|
5
|
-
puts "Started Importing"
|
6
|
-
puts "Params are: "
|
7
|
-
end
|
8
|
-
|
9
|
-
def self.export data
|
10
|
-
Export.new(data).start
|
11
|
-
end
|
1
|
+
require "edge_csv/version"
|
12
2
|
|
3
|
+
module EdgeCsv
|
4
|
+
VERSION = "0.0.1"
|
13
5
|
end
|
metadata
CHANGED
@@ -1,16 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: edge_csv
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dmitry Gusev
|
8
8
|
- Arvid Stahovskiy
|
9
|
-
- Igor Potapov
|
10
9
|
autorequire:
|
11
10
|
bindir: exe
|
12
11
|
cert_chain: []
|
13
|
-
date: 2017-
|
12
|
+
date: 2017-01-14 00:00:00.000000000 Z
|
14
13
|
dependencies:
|
15
14
|
- !ruby/object:Gem::Dependency
|
16
15
|
name: bundler
|
@@ -61,10 +60,8 @@ files:
|
|
61
60
|
- bin/setup
|
62
61
|
- edge_csv.gemspec
|
63
62
|
- lib/edge_csv.rb
|
64
|
-
- lib/edge_csv/export.rb
|
65
63
|
- lib/edge_csv/version.rb
|
66
|
-
|
67
|
-
homepage: http://rubygems.org/gems/edge_cs'
|
64
|
+
homepage: ''
|
68
65
|
licenses: []
|
69
66
|
metadata: {}
|
70
67
|
post_install_message:
|
data/lib/edge_csv/export.rb
DELETED
@@ -1,35 +0,0 @@
|
|
1
|
-
class Export
|
2
|
-
include ExportHelper
|
3
|
-
|
4
|
-
def initialize data
|
5
|
-
@name = data['name'] || 'new_csv'
|
6
|
-
@auto_send = data['auto_send'] || true
|
7
|
-
@headers = data['headers'] || true
|
8
|
-
@subjects = data['subjects'] || []
|
9
|
-
@fields = data['fields'] || get_fields(@subjects[0])
|
10
|
-
@sequence = data['sequence'] || []
|
11
|
-
end
|
12
|
-
|
13
|
-
def start
|
14
|
-
puts("Started export #{@name}")
|
15
|
-
if @auto_send
|
16
|
-
send_data(collect_csv, :filename => "#{@name}.csv", :type => "text/csv")
|
17
|
-
else
|
18
|
-
collect_csv
|
19
|
-
end
|
20
|
-
puts("Completed export #{@name}")
|
21
|
-
end
|
22
|
-
|
23
|
-
private
|
24
|
-
|
25
|
-
def collect_csv
|
26
|
-
header = convert_headers(@fields, @headers)
|
27
|
-
keys = sequences_headers(@sequence, @fields)
|
28
|
-
CSV.generate(headers: true) do |csv|
|
29
|
-
csv << header if @headers
|
30
|
-
@subjects.each{ |subject| csv << keys.map{ |key| subject[key] } }
|
31
|
-
end
|
32
|
-
end
|
33
|
-
|
34
|
-
|
35
|
-
end
|
@@ -1,22 +0,0 @@
|
|
1
|
-
module ExportHelper
|
2
|
-
|
3
|
-
def get_fields instance
|
4
|
-
instance = instance.attributes if instance.class != 'Hash'
|
5
|
-
internal_headers = instance.keys
|
6
|
-
internal_headers
|
7
|
-
end
|
8
|
-
|
9
|
-
def convert_headers(fields, headers)
|
10
|
-
fields.map{ |field| field.sub!('_', ' ').split(' ').map(&:capitalize).join(' ') }
|
11
|
-
headers.each do |initial, new|
|
12
|
-
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
def sequences_headers(sequence, fields)
|
17
|
-
keys = sequence
|
18
|
-
keys << fields - sequence
|
19
|
-
keys.flatten
|
20
|
-
end
|
21
|
-
|
22
|
-
end
|