lib/upgrade.rb in dev_tasks-0.0.83 vs lib/upgrade.rb in dev_tasks-0.0.84
- old
+ new
@@ -23,10 +23,14 @@
newest_file_rake_dir=nil
Dir.chdir(rake_dir) do
newest_file_rake_dir=rake_dir + '/' + Dir.glob("**/*").max_by {|f| File.mtime(f)}
end
- self.add "<%Environment.rake('#{rake_dir}','default')%>" if(File.mtime(newest_file_rake_dir) > File.mtime(DEV_TASKS[:newest_artifact]))
+ if(newest_file_rake_dir.nil?)
+ self.add "<%Environment.rake('#{rake_dir}','default')%>"
+ else
+ self.add "<%Environment.rake('#{rake_dir}','default')%>" if(File.mtime(newest_file_rake_dir) > File.mtime(DEV_TASKS[:newest_artifact]))
+ end
end
}
end
if(DEV_TASKS[:dependencies].has_key?(:source))
DEV_TASKS[:dependencies][:source].each{|source_dep|
\ No newline at end of file