raykit 0.0.542 → 0.0.543

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 64c75cbb239ad5c3d3a2b9837028f23f7002b02f61195fc5ed4f8e364f5e9a61
4
- data.tar.gz: 9787ee130f795f5004c70b66d3b9865877b2e724e3d5b1dc95015bb3a0305fc5
3
+ metadata.gz: 25dc28248121fe9e6fdfe7adfd70c9efd54b57aefaf7c8933548a67dcd19c6d6
4
+ data.tar.gz: 7c8aebad7fc0195c4183c10dc005aed2be71675c5f7368a18a6a90543e8e8f6d
5
5
  SHA512:
6
- metadata.gz: 040ec4774247b42c0b6dd2233dac25ad0f6042f7a401de48ccc06d26a07405d48d6a18b2deaf9d41a5609e2dcc4da0e10082ddea42f381dcf1a8a74fbd91f133
7
- data.tar.gz: 9181020d152aaef58ce1b1dfa197810859876f6983a20c6a355a56268eaae8f654507386b4669de0770ade3060fe7110602fa5fd84bd211e51b16fdab3f930eb
6
+ metadata.gz: 77782d30be9b691fdeaa8c9b22ea2029657c33b34cb042f048caf8abfa8bae09b3bdf7244e50a202b11d906ae4c913ee02466501b0e28f5da0a899d55e9e15f6
7
+ data.tar.gz: 6bd0e95c948d75ae32c546c81dad2de315422e83e6c087ab6e77ce2e6e8ff01ea76293114aaad9a8f809dbcd16f5ad00e91849cecfdbd4f7d33ff5efdd194cc4
@@ -75,20 +75,19 @@ module Raykit
75
75
 
76
76
  def last_modified_time
77
77
  Dir.chdir(@directory) do
78
-
79
78
  begin
80
- # Find the most recently modified file
81
- most_recent_file = Dir.glob("**/*.*").select { |f| File.file?(f) }.max_by { |f| File.mtime(f) }
82
-
83
- # Use File.mtime if a file was found, otherwise handle the nil case
84
- if most_recent_file
85
- last_modified_time = File.mtime(most_recent_file)
86
- else
87
- # Handle the case where no files are found. This could be setting a default value,
88
- # raising a custom error, or any other appropriate action depending on your needs.
89
- # For example, setting last_modified_time to Time.now or raising a custom error.
90
- last_modified_time = Time.now # Or any other appropriate action
91
- end
79
+ # Find the most recently modified file
80
+ most_recent_file = Dir.glob("**/*.*").select { |f| File.file?(f) }.max_by { |f| File.mtime(f) }
81
+
82
+ # Use File.mtime if a file was found, otherwise handle the nil case
83
+ if most_recent_file
84
+ last_modified_time = File.mtime(most_recent_file)
85
+ else
86
+ # Handle the case where no files are found. This could be setting a default value,
87
+ # raising a custom error, or any other appropriate action depending on your needs.
88
+ # For example, setting last_modified_time to Time.now or raising a custom error.
89
+ last_modified_time = Time.now # Or any other appropriate action
90
+ end
92
91
  rescue Errno::ENAMETOOLONG => e
93
92
  puts "Error: #{e.message}"
94
93
  last_modified_time = Time.now # Or any other appropriate action
data/lib/raykit/zip.rb CHANGED
@@ -40,7 +40,7 @@ module Raykit
40
40
  @include_globs.each do |include_glob|
41
41
  Dir.glob(include_glob) { |f|
42
42
  #puts "\n" + f
43
- files_to_archive << f
43
+ files_to_archive << f if File.file?(f)
44
44
  }
45
45
  end
46
46
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: raykit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.542
4
+ version: 0.0.543
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lou Parslow