genZPK 0.1.4 → 0.1.5

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 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="115" column="32" selection-start="2879" selection-end="2879" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2465">
39
+ <state line="100" column="13" selection-start="2353" selection-end="2353" vertical-scroll-proportion="0.0" vertical-offset="1369" 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="true" current-in-tab="true">
46
46
  <entry file="file://$PROJECT_DIR$/bin/genZPK">
47
47
  <provider selected="true" editor-type-id="text-editor">
48
- <state line="59" column="87" selection-start="1609" selection-end="1609" vertical-scroll-proportion="0.5978593" vertical-offset="612" max-vertical-offset="5457">
48
+ <state line="180" column="5" selection-start="5715" selection-end="5715" vertical-scroll-proportion="0.80062795" vertical-offset="2550" max-vertical-offset="5474">
49
49
  <folding />
50
50
  </state>
51
51
  </provider>
@@ -63,7 +63,7 @@
63
63
  <file leaf-file-name="test.xml" pinned="false" current="false" current-in-tab="false">
64
64
  <entry file="file://$PROJECT_DIR$/test.xml">
65
65
  <provider selected="true" editor-type-id="text-editor">
66
- <state line="195" column="33" selection-start="0" selection-end="22901" vertical-scroll-proportion="0.0" vertical-offset="2485" max-vertical-offset="6851">
66
+ <state line="62" column="19" selection-start="2806" selection-end="2806" vertical-scroll-proportion="0.0" vertical-offset="816" max-vertical-offset="6851">
67
67
  <folding />
68
68
  </state>
69
69
  </provider>
@@ -103,9 +103,9 @@
103
103
  <option value="$PROJECT_DIR$/Rakefile" />
104
104
  <option value="$PROJECT_DIR$/genZPK.gemspec" />
105
105
  <option value="$PROJECT_DIR$/lib/genZPK/templates.rb" />
106
- <option value="$PROJECT_DIR$/test.xml" />
107
106
  <option value="$PROJECT_DIR$/lib/genZPK.rb" />
108
107
  <option value="$PROJECT_DIR$/lib/genZPK/version.rb" />
108
+ <option value="$PROJECT_DIR$/test.xml" />
109
109
  <option value="$PROJECT_DIR$/bin/genZPK" />
110
110
  </list>
111
111
  </option>
@@ -332,7 +332,7 @@
332
332
  <editor active="true" />
333
333
  <layout>
334
334
  <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" />
335
- <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
+ <window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.3275862" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
336
336
  <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" />
337
337
  <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" />
338
338
  <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" />
@@ -340,7 +340,7 @@
340
340
  <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" />
341
341
  <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" />
342
342
  <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" />
343
- <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
+ <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.31034482" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
344
344
  <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" />
345
345
  <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" />
346
346
  <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" />
@@ -691,23 +691,23 @@
691
691
  </state>
692
692
  </provider>
693
693
  </entry>
694
- <entry file="file://$PROJECT_DIR$/test.xml">
694
+ <entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
695
695
  <provider selected="true" editor-type-id="text-editor">
696
- <state line="195" column="33" selection-start="0" selection-end="22901" vertical-scroll-proportion="0.0" vertical-offset="2485" max-vertical-offset="6851">
696
+ <state line="100" column="13" selection-start="2353" selection-end="2353" vertical-scroll-proportion="0.0" vertical-offset="1709" max-vertical-offset="2465">
697
697
  <folding />
698
698
  </state>
699
699
  </provider>
700
700
  </entry>
701
- <entry file="file://$PROJECT_DIR$/lib/genZPK.rb">
701
+ <entry file="file://$PROJECT_DIR$/test.xml">
702
702
  <provider selected="true" editor-type-id="text-editor">
703
- <state line="115" column="32" selection-start="2879" selection-end="2879" vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2465">
703
+ <state line="62" column="19" selection-start="2806" selection-end="2806" vertical-scroll-proportion="0.0" vertical-offset="816" max-vertical-offset="6851">
704
704
  <folding />
705
705
  </state>
706
706
  </provider>
707
707
  </entry>
708
708
  <entry file="file://$PROJECT_DIR$/bin/genZPK">
709
709
  <provider selected="true" editor-type-id="text-editor">
710
- <state line="59" column="87" selection-start="1609" selection-end="1609" vertical-scroll-proportion="0.5978593" vertical-offset="612" max-vertical-offset="5457">
710
+ <state line="180" column="5" selection-start="5715" selection-end="5715" vertical-scroll-proportion="0.80062795" vertical-offset="2550" max-vertical-offset="5474">
711
711
  <folding />
712
712
  </state>
713
713
  </provider>
data/bin/genZPK CHANGED
@@ -74,11 +74,6 @@ if options[:pull] == true
74
74
  end
75
75
  end
76
76
 
77
-
78
-
79
-
80
-
81
-
82
77
  if configHash["system"].has_key? "name"
83
78
  if not configHash["system"]["name"] == options[:system]
84
79
  warn "Could not find system \"#{options[:system]}\" in configuration. Please run genZPK --configure to setup checks for this system or verify the system name."
@@ -159,25 +154,31 @@ for i in 0..(checks.size - 1)
159
154
 
160
155
  contents = File.read(dir + filepath)
161
156
  matches = contents.scan(regex)
162
-
157
+ results = ""
158
+ passes = 0
163
159
  for i in 0..(matches.size - 1)
164
160
  match = matches[i]
165
161
 
166
162
  if not match[matchgrp] == matchval
167
- display << "." * (80 - "FAIL".size - desc.size)
168
- display << "FAIL\n"
169
- display << "\t#{dir + filepath}\n"
170
- display << "\tValue found: #{match[matchgrp]}\n"
171
- display << "\tRequired value: #{matchval}"
172
- puts display
173
- next
163
+ results << "\t#{dir + filepath}\n"
164
+ results << "\tValue found: #{match[matchgrp]}\n"
165
+ results << "\tRequired value: #{matchval}\n"
166
+ else
167
+ passes += 1
174
168
  end
175
169
  end
176
- display << "." * (80 - "SUCCESS".size - desc.size)
177
- display << "SUCCESS"
178
- puts display
179
170
 
180
- successes += 1
171
+ if passes == matches.size
172
+ display << "." * (80 - "SUCCESS".size - desc.size)
173
+ display << "SUCCESS"
174
+ puts display
175
+ successes += 1
176
+ else
177
+ display << "." * (80 - "FAIL".size - desc.size)
178
+ display << "FAIL"
179
+ puts display
180
+ puts results
181
+ end
181
182
  end
182
183
 
183
184
  puts "-" * 80
@@ -1,3 +1,3 @@
1
1
  module GenZPK
2
- VERSION = "0.1.4"
2
+ VERSION = "0.1.5"
3
3
  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
4
+ version: 0.1.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: