raykit 0.0.342 → 0.0.343

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7eb5daedd8b3abc1778c07d01dcf8bda6743e4fef81bbb2b14318d88c8b7df20
4
- data.tar.gz: 51d6fe6ef326bad0a84e75fe579878a63eb440e074d3d2bf9d357c971a6ec71d
3
+ metadata.gz: 928940e4a04947b45084a0ab4304e10986c6546ac9e443a69e36902710b92f51
4
+ data.tar.gz: 3298230170d281b269cdf360a337f0c5ecebd904f13e22ee0bfeb5a8770a5318
5
5
  SHA512:
6
- metadata.gz: b5b2a42034e7b25d7a4687861939251709c1312aa601391f03d2beeff13f68b894ac050fd3f127fbfd17c383e6b7fd9de25b538d2caf54bdb9c03490511dbe46
7
- data.tar.gz: a849b31695b13aea2bb725ea1e099dc295379b57ed489b4a70676451e21bcc5f5c5d0c9d9ad07fbd3a79cc659736314d5374873ca3af9d5c896f3e5b23e54a65
6
+ metadata.gz: 065f886c5218ab37bd4657548ea0165b4bbc3c5c45063316fc3fcc366ec749db28a1165c17648530b3ecb1bba49c48d3bdcc5f1fc2e41bdade216e4b676ba907
7
+ data.tar.gz: 31524ca7dd028b405188747d975e7809d8c038eb164bae0542627c3650125d8718c0079e75ff0b66dcaa4275a5a050768a0da79386e324c36f7ebf19854d9081
@@ -33,7 +33,6 @@ module Raykit
33
33
  end
34
34
 
35
35
  def initialize(command)
36
- #def initialize(command, timeout = 0, success_log_level = Logger::DEBUG, logging_enabled = true)
37
36
  timeout = 0
38
37
  success_log_level = nil
39
38
  logging_enabled = false
@@ -43,9 +42,7 @@ module Raykit
43
42
  @logging_enabled = logging_enabled
44
43
  @command = command
45
44
  @timeout = timeout
46
- #t = Time.now
47
45
  @elapsed = 0
48
- #run if @command.length.positive?
49
46
  self
50
47
  end
51
48
 
@@ -55,7 +52,6 @@ module Raykit
55
52
  end
56
53
 
57
54
  def run
58
- # puts '---running---'
59
55
  @start_time = Time.now
60
56
  @elapsed = 0
61
57
  timer = Timer.new
@@ -99,7 +95,6 @@ module Raykit
99
95
  if @exitstatus != 0
100
96
  to_log_event.to_seq
101
97
  else
102
- # puts '---logging---'
103
98
  unless @success_log_level.nil?
104
99
  e = to_log_event
105
100
  e["Level"] = "Verbose" if @success_log_level == "Verbose"
@@ -142,7 +137,7 @@ module Raykit
142
137
  "#{msg}\n"
143
138
  end
144
139
  secrets = Secrets.new
145
- msg = secrets.hide(@command) # "?"# self.summary(false)
140
+ msg = secrets.hide(@command)
146
141
  level = "Verbose"
147
142
  level = "Warning" if @exitstatus != 0
148
143
  event = Raykit::LogEvent.new(level, msg, {
@@ -187,7 +182,7 @@ module Raykit
187
182
  symbol = Rainbow(error.encode("utf-8")).red if @exitstatus != 0
188
183
  cmd = "#{Rainbow(SECRETS.hide(@command)).yellow}"
189
184
  if show_directory
190
- puts "#{symbol} #{cmd} " + Rainbow("#{elapsed_str}").cyan #(#{@directory},#{elapsed_str})"
185
+ puts "#{symbol} #{cmd} " + Rainbow("#{elapsed_str}").cyan
191
186
  puts Rainbow(" #{@directory}").cyan
192
187
  else
193
188
  puts "#{symbol} #{Rainbow(SECRETS.hide(@command)).yellow} (#{elapsed_str})"
@@ -206,10 +201,6 @@ module Raykit
206
201
  puts " " + line
207
202
  end
208
203
  end
209
- # summary
210
- #puts @output
211
- #puts @error
212
- #puts
213
204
  end
214
205
 
215
206
  def save
@@ -259,7 +250,6 @@ module Raykit
259
250
  end
260
251
 
261
252
  def self.parse_yaml_commands(yaml)
262
- # commands=Array.new()
263
253
  data = YAML.safe_load(yaml)
264
254
  commands = get_script_commands(data)
265
255
  end
@@ -82,8 +82,6 @@ module Raykit
82
82
  verb_descriptions.each do |k, v|
83
83
  puts "#{k.ljust(15, " ")} - #{v}"
84
84
  end
85
- # puts @opts
86
- # puts "verbs: " + verbs.to_s
87
85
  0
88
86
  end
89
87
 
@@ -282,5 +280,3 @@ module Raykit
282
280
  end
283
281
  end
284
282
  end
285
-
286
- # CONSOLE=Raykit::Console.new
@@ -0,0 +1,7 @@
1
+ module Raykit
2
+ class NUnit
3
+ def self.nunit3console_path(version)
4
+ "#{Environment.home_dir}/.nuget/packages/nunit.consolerunner/#{version}/tools"
5
+ end
6
+ end
7
+ end
@@ -284,7 +284,7 @@ module Raykit
284
284
 
285
285
  def run(command, quit_on_failure = true)
286
286
  if command.is_a?(Array)
287
- command.each { |subcommand| run(subcommand, quit_on_failure) }
287
+ command.each { |subcommand| run(subcommand, quit_on_failure, success_log_level) }
288
288
  else
289
289
  cmd = Command.new(command).set_timeout(0).run
290
290
  cmd.summary
data/lib/raykit/zip.rb CHANGED
@@ -1,5 +1,4 @@
1
1
  # frozen_string_literal: true
2
- require "zip"
3
2
 
4
3
  module Raykit
5
4
  class Zip
@@ -35,28 +34,11 @@ module Raykit
35
34
  path = File.dirname(@filename)
36
35
  FileUtils.mkdir_p(path) unless Dir.exist?(path)
37
36
 
38
- files_to_archive = Array::new()
39
37
  Dir.chdir(@source_dir) do
40
- #include_files = []
38
+ include_files = []
41
39
  @include_globs.each do |include_glob|
42
- Dir.glob(include_glob) { |f|
43
- puts "\n" + f
44
- files_to_archive << f
45
- }
46
40
  end
47
41
  end
48
-
49
- ::Zip::File::open(@filename, ::Zip::File::CREATE) { |zipfile|
50
- files_to_archive.each do |file|
51
- zipfile.get_output_stream(file) { |f|
52
- fr = ::File.open("#{@source_dir}/#{file}", "rb")
53
- f.puts(fr.read)
54
- fr.close()
55
- f.close()
56
- }
57
- end
58
- zipfile.close
59
- }
60
42
  end
61
43
  end
62
44
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: raykit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.342
4
+ version: 0.0.343
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lou Parslow
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-02-24 00:00:00.000000000 Z
11
+ date: 2022-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -93,6 +93,7 @@ files:
93
93
  - lib/raykit/logging.rb
94
94
  - lib/raykit/msbuild.rb
95
95
  - lib/raykit/nugetpackage.rb
96
+ - lib/raykit/nunit.rb
96
97
  - lib/raykit/project.rb
97
98
  - lib/raykit/rake.rb
98
99
  - lib/raykit/runner.rb
@@ -125,7 +126,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
126
  - !ruby/object:Gem::Version
126
127
  version: '0'
127
128
  requirements: []
128
- rubygems_version: 3.2.22
129
+ rubygems_version: 3.2.15
129
130
  signing_key:
130
131
  specification_version: 4
131
132
  summary: ruby gem to support rake ci/cd tasks