dir-to-xml 1.1.1 → 1.1.2

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: 372af34f7da498e42ef32c51ee16e6c4f4270f70363d937f577390e1c690ba04
4
- data.tar.gz: 49f55f26145a5b0d43120f2a06601641ef1e1dc39acf1be24e9993d78421b333
3
+ metadata.gz: 3abbbcbec98ad9435fd8032a23da267df6e9009e50f854e6ec0dc2b5eadeb35d
4
+ data.tar.gz: cb0d28da749982e7dae85ce547eaed51b39b63ef12e2bab57352a32a051389af
5
5
  SHA512:
6
- metadata.gz: ff46b964f643d8d32d0f681596d1e8c4d193fe967775cfaf5502d52aa28ef6f906c5811d607ac9d9147ba1dae6374ba8b4704306ff1e679dead279e609d0f5a1
7
- data.tar.gz: 65a8b57721dd15a038e9190e736355476d052d63f535c9386024bd5c01099870d8d01e0f80bc92ca7314e47fcf2d72f061af6c19a953463a3e174185ee9b0a00
6
+ metadata.gz: d5c672578f47b4ef23b2b9fd1a2ea7359e78f1c0084c168128ee4dfbb706bdecc0f0a2f813e851cb4965bf00669fa4dfd751644fff2401c64f1e3f61e86c67c9
7
+ data.tar.gz: 57e2f7d63483f4c601c35a2d69d5e53e69bb25c6119995e1a88faa41596c6d02e541ac87317d6faa5dc3d9f39ca8c558bf5eb378e12482e683b73414571cf4b9
checksums.yaml.gz.sig CHANGED
Binary file
data/lib/dir-to-xml.rb CHANGED
@@ -127,10 +127,13 @@ class DirToXML
127
127
  dtx_last_modified = Time.parse(@dx.last_modified)
128
128
 
129
129
  select_records = records.select do |file|
130
- file[:mtime] > dtx_last_modified
130
+
131
+ file[:mtime] > dtx_last_modified or file[:type] == 'directory'
132
+
131
133
  end
132
134
 
133
- find_latest(select_records)
135
+ puts 'select_records: ' + select_records.inspect if @debug
136
+ find_latest(select_records) if select_records.any?
134
137
 
135
138
  # Add any new files
136
139
  #
@@ -202,12 +205,12 @@ class DirToXML
202
205
  or latest_file.nil? \
203
206
  or latest_file[:type] == 'directory') then
204
207
 
205
- dir_latest.last[:path] = File.join(@path, dir_latest.first)
208
+ dir_latest.last[:path] = File.expand_path(File.join(@path, dir_latest.first))
206
209
  dir_latest.last
207
210
 
208
211
  elsif latest_file and latest_file[:type] == 'file'
209
212
 
210
- latest_file[:path] = @path
213
+ latest_file[:path] = File.expand_path(@path)
211
214
  latest_file
212
215
 
213
216
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dir-to-xml
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
metadata.gz.sig CHANGED
Binary file