genZPK 0.1.2 → 0.1.3
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.
- data/.idea/workspace.xml +166 -41
- data/bin/genZPK +139 -48
- data/lib/genZPK/version.rb +1 -1
- data/lib/genZPK.rb +13 -1
- metadata +2 -2
data/.idea/workspace.xml
CHANGED
@@ -36,7 +36,7 @@
|
|
36
36
|
<file leaf-file-name="genZPK.rb" pinned="false" current="false" current-in-tab="false">
|
37
37
|
<entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
|
38
38
|
<provider selected="true" editor-type-id="text-editor">
|
39
|
-
<state line="
|
39
|
+
<state line="138" column="5" selection-start="3447" selection-end="3447" vertical-scroll-proportion="0.0" vertical-offset="1731" max-vertical-offset="2465">
|
40
40
|
<folding />
|
41
41
|
</state>
|
42
42
|
</provider>
|
@@ -45,7 +45,7 @@
|
|
45
45
|
<file leaf-file-name="genZPK" pinned="false" current="false" current-in-tab="false">
|
46
46
|
<entry file="file://$PROJECT_DIR$/bin/genZPK">
|
47
47
|
<provider selected="true" editor-type-id="text-editor">
|
48
|
-
<state line="
|
48
|
+
<state line="294" column="24" selection-start="8779" selection-end="8779" vertical-scroll-proportion="0.0" vertical-offset="4140" max-vertical-offset="5457">
|
49
49
|
<folding />
|
50
50
|
</state>
|
51
51
|
</provider>
|
@@ -54,7 +54,7 @@
|
|
54
54
|
<file leaf-file-name="version.rb" pinned="false" current="true" current-in-tab="true">
|
55
55
|
<entry file="file://$PROJECT_DIR$/lib/genZPK/version.rb">
|
56
56
|
<provider selected="true" editor-type-id="text-editor">
|
57
|
-
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.
|
57
|
+
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.025993884" vertical-offset="0" max-vertical-offset="654">
|
58
58
|
<folding />
|
59
59
|
</state>
|
60
60
|
</provider>
|
@@ -63,16 +63,7 @@
|
|
63
63
|
<file leaf-file-name="templates.rb" pinned="false" current="false" current-in-tab="false">
|
64
64
|
<entry file="file://$PROJECT_DIR$/lib/genZPK/templates.rb">
|
65
65
|
<provider selected="true" editor-type-id="text-editor">
|
66
|
-
<state line="
|
67
|
-
<folding />
|
68
|
-
</state>
|
69
|
-
</provider>
|
70
|
-
</entry>
|
71
|
-
</file>
|
72
|
-
<file leaf-file-name="test.xml" pinned="false" current="false" current-in-tab="false">
|
73
|
-
<entry file="file://$PROJECT_DIR$/test.xml">
|
74
|
-
<provider selected="true" editor-type-id="text-editor">
|
75
|
-
<state line="3" column="29" selection-start="77" selection-end="77" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="255">
|
66
|
+
<state line="127" column="22" selection-start="4711" selection-end="4711" vertical-scroll-proportion="0.0" vertical-offset="1759" max-vertical-offset="2703">
|
76
67
|
<folding />
|
77
68
|
</state>
|
78
69
|
</provider>
|
@@ -81,7 +72,7 @@
|
|
81
72
|
<file leaf-file-name="genZPK.gemspec" pinned="false" current="false" current-in-tab="false">
|
82
73
|
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
83
74
|
<provider selected="true" editor-type-id="text-editor">
|
84
|
-
<state line="24" column="3" selection-start="1002" selection-end="1002" vertical-scroll-proportion="0.0" vertical-offset="
|
75
|
+
<state line="24" column="3" selection-start="1002" selection-end="1002" vertical-scroll-proportion="0.0" vertical-offset="408" max-vertical-offset="510">
|
85
76
|
<folding />
|
86
77
|
</state>
|
87
78
|
</provider>
|
@@ -102,18 +93,19 @@
|
|
102
93
|
<list>
|
103
94
|
<option value="$PROJECT_DIR$/Rakefile" />
|
104
95
|
<option value="$PROJECT_DIR$/genZPK.gemspec" />
|
105
|
-
<option value="$PROJECT_DIR$/lib/genZPK.rb" />
|
106
|
-
<option value="$PROJECT_DIR$/test.xml" />
|
107
96
|
<option value="$PROJECT_DIR$/lib/genZPK/templates.rb" />
|
97
|
+
<option value="$PROJECT_DIR$/test.xml" />
|
98
|
+
<option value="$PROJECT_DIR$/lib/genZPK.rb" />
|
108
99
|
<option value="$PROJECT_DIR$/bin/genZPK" />
|
109
100
|
<option value="$PROJECT_DIR$/lib/genZPK/version.rb" />
|
110
101
|
</list>
|
111
102
|
</option>
|
112
103
|
</component>
|
113
104
|
<component name="ProjectFrameBounds">
|
114
|
-
<option name="x" value="
|
115
|
-
<option name="
|
116
|
-
<option name="
|
105
|
+
<option name="x" value="56" />
|
106
|
+
<option name="y" value="-8" />
|
107
|
+
<option name="width" value="1872" />
|
108
|
+
<option name="height" value="1096" />
|
117
109
|
</component>
|
118
110
|
<component name="ProjectLevelVcsManager" settingsEditedManually="true">
|
119
111
|
<OptionsSetting value="true" id="Add" />
|
@@ -141,6 +133,7 @@
|
|
141
133
|
<sortByType />
|
142
134
|
</navigator>
|
143
135
|
<panes>
|
136
|
+
<pane id="Scope" />
|
144
137
|
<pane id="ProjectPane">
|
145
138
|
<subPane>
|
146
139
|
<PATH>
|
@@ -211,11 +204,10 @@
|
|
211
204
|
</PATH>
|
212
205
|
</subPane>
|
213
206
|
</pane>
|
214
|
-
<pane id="Scope" />
|
215
207
|
</panes>
|
216
208
|
</component>
|
217
209
|
<component name="PropertiesComponent">
|
218
|
-
<property name="options.lastSelected" value="
|
210
|
+
<property name="options.lastSelected" value="terminal" />
|
219
211
|
<property name="options.splitter.main.proportions" value="0.3" />
|
220
212
|
<property name="options.splitter.details.proportions" value="0.2" />
|
221
213
|
<property name="options.searchVisible" value="true" />
|
@@ -327,19 +319,19 @@
|
|
327
319
|
<servers />
|
328
320
|
</component>
|
329
321
|
<component name="ToolWindowManager">
|
330
|
-
<frame x="
|
322
|
+
<frame x="56" y="-8" width="1872" height="1096" extended-state="6" />
|
331
323
|
<editor active="true" />
|
332
324
|
<layout>
|
333
325
|
<window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
334
|
-
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="
|
326
|
+
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.3275862" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
335
327
|
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
|
336
328
|
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
337
329
|
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
338
|
-
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.
|
330
|
+
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.10021552" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
339
331
|
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
340
332
|
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" />
|
341
333
|
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
|
342
|
-
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="
|
334
|
+
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.31034482" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
343
335
|
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
344
336
|
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
|
345
337
|
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
@@ -368,6 +360,147 @@
|
|
368
360
|
<breakpoint-manager />
|
369
361
|
</component>
|
370
362
|
<component name="editorHistoryManager">
|
363
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/version.rb">
|
364
|
+
<provider selected="true" editor-type-id="text-editor">
|
365
|
+
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.0" vertical-offset="17" max-vertical-offset="136">
|
366
|
+
<folding />
|
367
|
+
</state>
|
368
|
+
</provider>
|
369
|
+
</entry>
|
370
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/templates.rb">
|
371
|
+
<provider selected="true" editor-type-id="text-editor">
|
372
|
+
<state line="127" column="22" selection-start="4711" selection-end="4711" vertical-scroll-proportion="0.0" vertical-offset="1759" max-vertical-offset="2703">
|
373
|
+
<folding />
|
374
|
+
</state>
|
375
|
+
</provider>
|
376
|
+
</entry>
|
377
|
+
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
378
|
+
<provider selected="true" editor-type-id="text-editor">
|
379
|
+
<state line="24" column="3" selection-start="1002" selection-end="1002" vertical-scroll-proportion="0.0" vertical-offset="408" max-vertical-offset="510">
|
380
|
+
<folding />
|
381
|
+
</state>
|
382
|
+
</provider>
|
383
|
+
</entry>
|
384
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
|
385
|
+
<provider selected="true" editor-type-id="text-editor">
|
386
|
+
<state line="64" column="27" selection-start="1529" selection-end="1529" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2261">
|
387
|
+
<folding />
|
388
|
+
</state>
|
389
|
+
</provider>
|
390
|
+
</entry>
|
391
|
+
<entry file="file://$PROJECT_DIR$/bin/genZPK">
|
392
|
+
<provider selected="true" editor-type-id="text-editor">
|
393
|
+
<state line="157" column="0" selection-start="4085" selection-end="4085" vertical-scroll-proportion="0.0" vertical-offset="2363" max-vertical-offset="3910">
|
394
|
+
<folding />
|
395
|
+
</state>
|
396
|
+
</provider>
|
397
|
+
</entry>
|
398
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/version.rb">
|
399
|
+
<provider selected="true" editor-type-id="text-editor">
|
400
|
+
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.0" vertical-offset="17" max-vertical-offset="136">
|
401
|
+
<folding />
|
402
|
+
</state>
|
403
|
+
</provider>
|
404
|
+
</entry>
|
405
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/templates.rb">
|
406
|
+
<provider selected="true" editor-type-id="text-editor">
|
407
|
+
<state line="146" column="61" selection-start="4612" selection-end="5116" vertical-scroll-proportion="0.0" vertical-offset="1759" max-vertical-offset="2703">
|
408
|
+
<folding />
|
409
|
+
</state>
|
410
|
+
</provider>
|
411
|
+
</entry>
|
412
|
+
<entry file="file://$PROJECT_DIR$/test.xml">
|
413
|
+
<provider selected="true" editor-type-id="text-editor">
|
414
|
+
<state line="164" column="59" selection-start="5716" selection-end="5746" vertical-scroll-proportion="0.0" vertical-offset="2349" max-vertical-offset="4284" />
|
415
|
+
</provider>
|
416
|
+
</entry>
|
417
|
+
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
418
|
+
<provider selected="true" editor-type-id="text-editor">
|
419
|
+
<state line="24" column="3" selection-start="1002" selection-end="1002" vertical-scroll-proportion="0.0" vertical-offset="408" max-vertical-offset="510">
|
420
|
+
<folding />
|
421
|
+
</state>
|
422
|
+
</provider>
|
423
|
+
</entry>
|
424
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
|
425
|
+
<provider selected="true" editor-type-id="text-editor">
|
426
|
+
<state line="64" column="27" selection-start="1529" selection-end="1529" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2261">
|
427
|
+
<folding />
|
428
|
+
</state>
|
429
|
+
</provider>
|
430
|
+
</entry>
|
431
|
+
<entry file="file://$PROJECT_DIR$/bin/genZPK">
|
432
|
+
<provider selected="true" editor-type-id="text-editor">
|
433
|
+
<state line="157" column="0" selection-start="4085" selection-end="4085" vertical-scroll-proportion="0.0" vertical-offset="2363" max-vertical-offset="3910">
|
434
|
+
<folding />
|
435
|
+
</state>
|
436
|
+
</provider>
|
437
|
+
</entry>
|
438
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/version.rb">
|
439
|
+
<provider selected="true" editor-type-id="text-editor">
|
440
|
+
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.0" vertical-offset="17" max-vertical-offset="136">
|
441
|
+
<folding />
|
442
|
+
</state>
|
443
|
+
</provider>
|
444
|
+
</entry>
|
445
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/templates.rb">
|
446
|
+
<provider selected="true" editor-type-id="text-editor">
|
447
|
+
<state line="146" column="61" selection-start="4612" selection-end="5116" vertical-scroll-proportion="0.0" vertical-offset="1951" max-vertical-offset="2703">
|
448
|
+
<folding />
|
449
|
+
</state>
|
450
|
+
</provider>
|
451
|
+
</entry>
|
452
|
+
<entry file="file://$PROJECT_DIR$/test.xml">
|
453
|
+
<provider selected="true" editor-type-id="text-editor">
|
454
|
+
<state line="4" column="29" selection-start="88" selection-end="88" vertical-scroll-proportion="0.0" vertical-offset="17" max-vertical-offset="4284" />
|
455
|
+
</provider>
|
456
|
+
</entry>
|
457
|
+
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
458
|
+
<provider selected="true" editor-type-id="text-editor">
|
459
|
+
<state line="24" column="3" selection-start="1002" selection-end="1002" vertical-scroll-proportion="0.0" vertical-offset="408" max-vertical-offset="510">
|
460
|
+
<folding />
|
461
|
+
</state>
|
462
|
+
</provider>
|
463
|
+
</entry>
|
464
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
|
465
|
+
<provider selected="true" editor-type-id="text-editor">
|
466
|
+
<state line="64" column="27" selection-start="1529" selection-end="1529" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2261">
|
467
|
+
<folding />
|
468
|
+
</state>
|
469
|
+
</provider>
|
470
|
+
</entry>
|
471
|
+
<entry file="file://$PROJECT_DIR$/bin/genZPK">
|
472
|
+
<provider selected="true" editor-type-id="text-editor">
|
473
|
+
<state line="157" column="0" selection-start="4085" selection-end="4085" vertical-scroll-proportion="0.0" vertical-offset="2363" max-vertical-offset="3910">
|
474
|
+
<folding />
|
475
|
+
</state>
|
476
|
+
</provider>
|
477
|
+
</entry>
|
478
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/version.rb">
|
479
|
+
<provider selected="true" editor-type-id="text-editor">
|
480
|
+
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.0" vertical-offset="17" max-vertical-offset="136">
|
481
|
+
<folding />
|
482
|
+
</state>
|
483
|
+
</provider>
|
484
|
+
</entry>
|
485
|
+
<entry file="file://$PROJECT_DIR$/lib/genZPK/templates.rb">
|
486
|
+
<provider selected="true" editor-type-id="text-editor">
|
487
|
+
<state line="87" column="10" selection-start="2574" selection-end="2574" vertical-scroll-proportion="0.0" vertical-offset="1258" max-vertical-offset="2703">
|
488
|
+
<folding />
|
489
|
+
</state>
|
490
|
+
</provider>
|
491
|
+
</entry>
|
492
|
+
<entry file="file://$PROJECT_DIR$/test.xml">
|
493
|
+
<provider selected="true" editor-type-id="text-editor">
|
494
|
+
<state line="4" column="29" selection-start="88" selection-end="88" vertical-scroll-proportion="0.0" vertical-offset="17" max-vertical-offset="4284" />
|
495
|
+
</provider>
|
496
|
+
</entry>
|
497
|
+
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
498
|
+
<provider selected="true" editor-type-id="text-editor">
|
499
|
+
<state line="24" column="3" selection-start="1002" selection-end="1002" vertical-scroll-proportion="0.0" vertical-offset="408" max-vertical-offset="510">
|
500
|
+
<folding />
|
501
|
+
</state>
|
502
|
+
</provider>
|
503
|
+
</entry>
|
371
504
|
<entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
|
372
505
|
<provider selected="true" editor-type-id="text-editor">
|
373
506
|
<state line="19" column="10" selection-start="403" selection-end="403" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2261">
|
@@ -398,9 +531,7 @@
|
|
398
531
|
</entry>
|
399
532
|
<entry file="file://$PROJECT_DIR$/test.xml">
|
400
533
|
<provider selected="true" editor-type-id="text-editor">
|
401
|
-
<state line="9" column="9" selection-start="243" selection-end="243" vertical-scroll-proportion="0.0" vertical-offset="153" max-vertical-offset="255"
|
402
|
-
<folding />
|
403
|
-
</state>
|
534
|
+
<state line="9" column="9" selection-start="243" selection-end="243" vertical-scroll-proportion="0.0" vertical-offset="153" max-vertical-offset="255" />
|
404
535
|
</provider>
|
405
536
|
</entry>
|
406
537
|
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
@@ -440,9 +571,7 @@
|
|
440
571
|
</entry>
|
441
572
|
<entry file="file://$PROJECT_DIR$/test.xml">
|
442
573
|
<provider selected="true" editor-type-id="text-editor">
|
443
|
-
<state line="22" column="11" selection-start="572" selection-end="572" vertical-scroll-proportion="0.0" vertical-offset="374" max-vertical-offset="510"
|
444
|
-
<folding />
|
445
|
-
</state>
|
574
|
+
<state line="22" column="11" selection-start="572" selection-end="572" vertical-scroll-proportion="0.0" vertical-offset="374" max-vertical-offset="510" />
|
446
575
|
</provider>
|
447
576
|
</entry>
|
448
577
|
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
@@ -529,9 +658,7 @@
|
|
529
658
|
</entry>
|
530
659
|
<entry file="file://$APPLICATION_HOME_DIR$/rubystubs193/object.rb">
|
531
660
|
<provider selected="true" editor-type-id="text-editor">
|
532
|
-
<state line="177" column="8" selection-start="6389" selection-end="6389" vertical-scroll-proportion="1.0967302" vertical-offset="2204" max-vertical-offset="13090"
|
533
|
-
<folding />
|
534
|
-
</state>
|
661
|
+
<state line="177" column="8" selection-start="6389" selection-end="6389" vertical-scroll-proportion="1.0967302" vertical-offset="2204" max-vertical-offset="13090" />
|
535
662
|
</provider>
|
536
663
|
</entry>
|
537
664
|
<entry file="file://$PROJECT_DIR$/genZPK.gemspec">
|
@@ -543,35 +670,33 @@
|
|
543
670
|
</entry>
|
544
671
|
<entry file="file://$PROJECT_DIR$/test.xml">
|
545
672
|
<provider selected="true" editor-type-id="text-editor">
|
546
|
-
<state line="
|
547
|
-
<folding />
|
548
|
-
</state>
|
673
|
+
<state line="206" column="68" selection-start="10645" selection-end="10645" vertical-scroll-proportion="0.3631124" vertical-offset="3250" max-vertical-offset="6851" />
|
549
674
|
</provider>
|
550
675
|
</entry>
|
551
676
|
<entry file="file://$PROJECT_DIR$/lib/genZPK/templates.rb">
|
552
677
|
<provider selected="true" editor-type-id="text-editor">
|
553
|
-
<state line="
|
678
|
+
<state line="127" column="22" selection-start="4711" selection-end="4711" vertical-scroll-proportion="0.0" vertical-offset="1759" max-vertical-offset="2703">
|
554
679
|
<folding />
|
555
680
|
</state>
|
556
681
|
</provider>
|
557
682
|
</entry>
|
558
683
|
<entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
|
559
684
|
<provider selected="true" editor-type-id="text-editor">
|
560
|
-
<state line="
|
685
|
+
<state line="138" column="5" selection-start="3447" selection-end="3447" vertical-scroll-proportion="0.0" vertical-offset="1731" max-vertical-offset="2465">
|
561
686
|
<folding />
|
562
687
|
</state>
|
563
688
|
</provider>
|
564
689
|
</entry>
|
565
690
|
<entry file="file://$PROJECT_DIR$/bin/genZPK">
|
566
691
|
<provider selected="true" editor-type-id="text-editor">
|
567
|
-
<state line="
|
692
|
+
<state line="294" column="24" selection-start="8779" selection-end="8779" vertical-scroll-proportion="0.0" vertical-offset="4140" max-vertical-offset="5457">
|
568
693
|
<folding />
|
569
694
|
</state>
|
570
695
|
</provider>
|
571
696
|
</entry>
|
572
697
|
<entry file="file://$PROJECT_DIR$/lib/genZPK/version.rb">
|
573
698
|
<provider selected="true" editor-type-id="text-editor">
|
574
|
-
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.
|
699
|
+
<state line="1" column="18" selection-start="32" selection-end="32" vertical-scroll-proportion="0.025993884" vertical-offset="0" max-vertical-offset="654">
|
575
700
|
<folding />
|
576
701
|
</state>
|
577
702
|
</provider>
|
data/bin/genZPK
CHANGED
@@ -5,18 +5,12 @@ require 'erb'
|
|
5
5
|
require 'genZPK'
|
6
6
|
require 'xmlsimple'
|
7
7
|
include GenZPK
|
8
|
-
=begin
|
9
|
-
cd /var/www/uat/
|
10
|
-
run checks
|
11
|
-
nano deployment.xml
|
12
|
-
rm -rf INSXCloud-UAT.zpk
|
13
|
-
sudo /usr/local/zend/bin/zdpack pack uat/
|
14
|
-
=end
|
15
8
|
|
16
9
|
|
17
10
|
options = {}
|
18
11
|
|
19
12
|
opt_parser = OptionParser.new do |opt|
|
13
|
+
|
20
14
|
opt.banner = "Usage: genZPK -s SYSTEM -v ZPK_VERSION -n PACKAGE_NAME DIR"
|
21
15
|
opt.separator "Initial configuration: genZPK --configure "
|
22
16
|
opt.separator ""
|
@@ -32,11 +26,16 @@ opt_parser = OptionParser.new do |opt|
|
|
32
26
|
options[:name] = name
|
33
27
|
end
|
34
28
|
|
29
|
+
opt.on("-p","--pull", "run \"git pull origin master\" prior to packaging") do
|
30
|
+
options[:pull] = true
|
31
|
+
end
|
32
|
+
|
35
33
|
opt.on("--configure","perform the initial configuration to setup checks prior to packaging") do
|
36
34
|
GenZPK::doConfigure
|
37
35
|
exit 0
|
38
36
|
end
|
39
37
|
|
38
|
+
|
40
39
|
opt.on("--version", "prints the version of this application") do
|
41
40
|
puts GenZPK::VERSION
|
42
41
|
exit 0
|
@@ -46,6 +45,8 @@ opt_parser = OptionParser.new do |opt|
|
|
46
45
|
puts opt_parser
|
47
46
|
end
|
48
47
|
end
|
48
|
+
|
49
|
+
|
49
50
|
begin
|
50
51
|
opt_parser.parse!
|
51
52
|
rescue OptionParser::InvalidOption
|
@@ -53,70 +54,76 @@ rescue OptionParser::InvalidOption
|
|
53
54
|
exit -1
|
54
55
|
end
|
55
56
|
|
56
|
-
|
57
|
-
warn "Unable to locate configuration files. Please run genZPK --configure"
|
58
|
-
exit -1
|
59
|
-
end
|
57
|
+
dir = String(ARGV[0]).end_with?('/') ? String(ARGV[0]).chomp : String(ARGV[0])
|
60
58
|
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
59
|
+
requireCondition File.exists?(File.expand_path '~/.genZPK/checks.xml'), "Unable to locate configuration files. Please run genZPK --configure"
|
60
|
+
requireCondition (File.read(File.expand_path('~/.genZPK/checks.xml')).gsub(/\s+/, "") == ""), "Configuration empty. Please run genZPK --configure"
|
61
|
+
requireCondition getZdpack.not_nil?, "unable to locate zdpack executable. Please check zend server installation at /usr/local/zend/"
|
62
|
+
requireCondition dir.not_nil?,"Required parameters not set or invalid argument. Please run genZPK --help for more info."
|
63
|
+
requireCondition options[:system].not_nil?,"Required parameters not set or invalid argument. Please run genZPK --help for more info."
|
64
|
+
requireCondition options[:version].not_nil?,"Required parameters not set or invalid argument. Please run genZPK --help for more info."
|
65
|
+
requireCondition options[:name].not_nil?,"Required parameters not set or invalid argument. Please run genZPK --help for more info."
|
66
|
+
requireCondition File.exists?(dir), "Error: Directory \"#{dir}\" does not exist."
|
67
67
|
|
68
|
-
|
69
|
-
warn "unable to locate zdpack executable. Please check zend server installation at /usr/local/zend/"
|
70
|
-
exit -1
|
71
|
-
end
|
68
|
+
configHash = XmlSimple.xml_in(File.expand_path( '~/.genZPK/checks.xml'), {'KeyAttr' => 'name', 'ForceArray'=>false})
|
72
69
|
|
73
|
-
dir = ARGV[0]
|
74
70
|
|
75
|
-
if
|
76
|
-
|
77
|
-
|
71
|
+
if options[:pull] == true
|
72
|
+
Dir.chdir dir do
|
73
|
+
requireCondition system("git pull origin master"), "Unable to update code via git. Exiting..."
|
74
|
+
end
|
78
75
|
end
|
79
76
|
|
80
|
-
if String(dir).end_with? '/'
|
81
|
-
dir = dir.chomp
|
82
|
-
end
|
83
77
|
|
84
|
-
if not File.exists? dir
|
85
|
-
warn %q{Error: Directory "#{dir}" does not exist.}
|
86
|
-
exit -1
|
87
|
-
end
|
88
78
|
|
89
|
-
Dir.chdir dir
|
90
|
-
if not system("git pull origin master")
|
91
|
-
warn "Unable to update code via git. Exiting..."
|
92
|
-
Dir.chdir ".."
|
93
|
-
exit -1
|
94
|
-
end
|
95
|
-
Dir.chdir ".."
|
96
79
|
|
97
|
-
|
98
|
-
|
80
|
+
|
81
|
+
|
82
|
+
if configHash["system"].has_key? "name"
|
83
|
+
if not configHash["system"]["name"] == options[:system]
|
99
84
|
warn "Could not find system \"#{options[:system]}\" in configuration. Please run genZPK --configure to setup checks for this system or verify the system name."
|
100
85
|
exit -1
|
101
86
|
end
|
102
87
|
|
103
|
-
if
|
104
|
-
checks =
|
88
|
+
if configHash["system"]["checks"]["check"].is_a? Array
|
89
|
+
checks = configHash["system"]["checks"]["check"]
|
105
90
|
else
|
106
91
|
checks = Array.new
|
107
|
-
checks.push
|
92
|
+
checks.push configHash["system"]["checks"]["check"]
|
93
|
+
end
|
94
|
+
|
95
|
+
if configHash["system"].has_key? "subdomains"
|
96
|
+
if configHash["system"]["subdomains"]["file"].is_a? Array
|
97
|
+
subdomainChecks = configHash["system"]["subdomains"]["file"]
|
98
|
+
else
|
99
|
+
subdomainChecks = Array.new
|
100
|
+
subdomainChecks.push configHash["system"]["subdomains"]["file"]
|
101
|
+
end
|
102
|
+
else
|
103
|
+
subdomainChecks = nil
|
108
104
|
end
|
109
105
|
else
|
110
|
-
if not
|
106
|
+
if not configHash["system"].has_key? options[:system]
|
111
107
|
warn "Could not find system \"#{options[:system]}\" in configuration. Please run genZPK --configure to setup checks for this system or verify the system name."
|
112
108
|
exit -1
|
113
109
|
end
|
114
110
|
|
115
|
-
if
|
116
|
-
checks =
|
111
|
+
if configHash["system"][options[:system]]["checks"]["check"].is_a? Array
|
112
|
+
checks = configHash["system"][options[:system]]["checks"]["check"]
|
117
113
|
else
|
118
114
|
checks = Array.new
|
119
|
-
checks.push
|
115
|
+
checks.push configHash["system"][options[:system]]["checks"]["check"]
|
116
|
+
end
|
117
|
+
|
118
|
+
if configHash["system"][options[:system]].has_key? "subdomains"
|
119
|
+
if configHash["system"][options[:system]]["subdomains"]["file"].is_a? Array
|
120
|
+
subdomainChecks = configHash["system"][options[:system]]["subdomains"]["file"]
|
121
|
+
else
|
122
|
+
subdomainChecks = Array.new
|
123
|
+
subdomainChecks.push configHash["system"][options[:system]]["subdomains"]["file"]
|
124
|
+
end
|
125
|
+
else
|
126
|
+
subdomainChecks = nil
|
120
127
|
end
|
121
128
|
end
|
122
129
|
|
@@ -182,6 +189,90 @@ end
|
|
182
189
|
|
183
190
|
puts "All checks passed. Continuing..."
|
184
191
|
|
192
|
+
puts "-" * 80
|
193
|
+
puts "Verifying subdomains"
|
194
|
+
puts "-" * 80
|
195
|
+
|
196
|
+
successes = 0
|
197
|
+
|
198
|
+
for i in 0..(subdomainChecks.size - 1)
|
199
|
+
|
200
|
+
check = subdomainChecks[i]
|
201
|
+
path = check["path"]
|
202
|
+
|
203
|
+
display = path
|
204
|
+
|
205
|
+
if File.exists?(dir + path)
|
206
|
+
contents = File.read(dir + path)
|
207
|
+
fieldPasses = 0
|
208
|
+
|
209
|
+
check.each do |field, value|
|
210
|
+
if not field == "path"
|
211
|
+
if not configHash["definitions"]["definition"][field].nil?
|
212
|
+
begin
|
213
|
+
regex = /#{configHash["definitions"]["definition"][field]["regex"]["content"]}/
|
214
|
+
rescue RegexpError => e
|
215
|
+
puts "Invalid regular in configuration. Please run genZPK --configure\n#{e.message}"
|
216
|
+
exit -1
|
217
|
+
end
|
218
|
+
|
219
|
+
matchgrp = Integer(configHash["definitions"]["definition"][field]["regex"]["group"]) - 1
|
220
|
+
matches = contents.scan(regex)
|
221
|
+
|
222
|
+
if matches[0][0] == value
|
223
|
+
fieldPasses += 1
|
224
|
+
else
|
225
|
+
if display.end_with? "\n"
|
226
|
+
display << "\tField Failed: #{field}\n"
|
227
|
+
display << "\t\tValue: #{matches[0][0]}\n"
|
228
|
+
display << "\t\tDefined value: #{value}\n"
|
229
|
+
else
|
230
|
+
display << "\n\tField Failed: #{field}\n"
|
231
|
+
display << "\t\tValue: #{matches[0][0]}\n"
|
232
|
+
display << "\t\tDefined value: #{value}\n"
|
233
|
+
end
|
234
|
+
end
|
235
|
+
else
|
236
|
+
if display.end_with? "\n"
|
237
|
+
display << "\tField not defined: #{field}\n"
|
238
|
+
else
|
239
|
+
display << "\n\tField not defined: #{field}\n"
|
240
|
+
end
|
241
|
+
end
|
242
|
+
end
|
243
|
+
end
|
244
|
+
|
245
|
+
|
246
|
+
if fieldPasses == (check.size - 1)
|
247
|
+
display << "." * (80 - "SUCCESS".size - display.size)
|
248
|
+
display << "SUCCESS"
|
249
|
+
puts display
|
250
|
+
successes += 1
|
251
|
+
else
|
252
|
+
tmpString = "#{fieldPasses} of #{check.size - 1} fields verified"
|
253
|
+
display << tmpString
|
254
|
+
display << "." * (80 - "#{fieldPasses} of #{check.size - 1} fields verified".size - "FAIL".size)
|
255
|
+
display << "FAIL"
|
256
|
+
puts display
|
257
|
+
end
|
258
|
+
else
|
259
|
+
display << "." * (80 - "FAIL".size - display.size)
|
260
|
+
display << "FAIL\n"
|
261
|
+
display << "\tFile not found: #{dir + path}"
|
262
|
+
puts display
|
263
|
+
end
|
264
|
+
end
|
265
|
+
|
266
|
+
puts "-" * 80
|
267
|
+
|
268
|
+
if not successes == subdomainChecks.size
|
269
|
+
puts "#{successes} of #{subdomainChecks.size} subdomains passed. Please check files listed above and try again."
|
270
|
+
exit -1
|
271
|
+
end
|
272
|
+
|
273
|
+
puts "All subdomains passed. Continuing..."
|
274
|
+
|
275
|
+
|
185
276
|
if not File.exists? dir + "/scripts"
|
186
277
|
FileUtils.mkpath dir + "/scripts"
|
187
278
|
end
|
data/lib/genZPK/version.rb
CHANGED
data/lib/genZPK.rb
CHANGED
@@ -4,6 +4,12 @@ require 'tempfile'
|
|
4
4
|
require 'nokogiri'
|
5
5
|
require 'highline/import'
|
6
6
|
|
7
|
+
class Object
|
8
|
+
def not_nil?
|
9
|
+
!nil?
|
10
|
+
end
|
11
|
+
end
|
12
|
+
|
7
13
|
module GenZPK
|
8
14
|
def getZdpack
|
9
15
|
if File.exists? '/usr/local/zend/bin/zdpack'
|
@@ -70,6 +76,13 @@ module GenZPK
|
|
70
76
|
a == 'y'
|
71
77
|
end
|
72
78
|
|
79
|
+
def requireCondition(condition, message)
|
80
|
+
if not condition
|
81
|
+
puts message
|
82
|
+
exit -1
|
83
|
+
end
|
84
|
+
end
|
85
|
+
|
73
86
|
def doConfigure
|
74
87
|
if not File.exists?(File.expand_path '~/.genZPK')
|
75
88
|
FileUtils.mkpath(File.expand_path '~/.genZPK')
|
@@ -124,5 +137,4 @@ module GenZPK
|
|
124
137
|
tmpChecksFile.close
|
125
138
|
tmpChecksFile.unlink
|
126
139
|
end
|
127
|
-
|
128
140
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: genZPK
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-12-
|
12
|
+
date: 2013-12-23 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: nokogiri
|