lib/dev_tasks.rb in dev_tasks-0.0.69 vs lib/dev_tasks.rb in dev_tasks-0.0.70
- old
+ new
@@ -54,11 +54,15 @@
self[:commands]=Commands.new if !has_key?(:commands)
self[:commands].update
self[:up_to_date] = false
if(allartifactsexist && !self[:oldest_artifact].nil? && !self[:newest_src_file].nil? && File.exists?(self[:oldest_artifact]) && File.exists?(self[:newest_src_file]))
- self[:command_order]=['pull','upgrade'] if(File.mtime(self[:oldest_artifact]) > File.mtime(self[:newest_src_file]))
- self[:up_to_date]=true
+ if(File.mtime(self[:oldest_artifact]) > File.mtime(self[:newest_src_file]))
+ self[:command_order]=['pull'] if(File.mtime(self[:oldest_artifact]) > File.mtime(self[:newest_src_file]))
+ self[:up_to_date]=true
+ end
+ self[:oldest_artifact_mtime]=File.mtime(self[:oldest_artifact]).to_s
+ self[:newest_src_file_mtime]=File.mtime(self[:newest_src_file]).to_s
end
update_tasks
end
def execute cmd