lib/upgrade.rb in dev_tasks-0.0.51 vs lib/upgrade.rb in dev_tasks-0.0.52

- old
+ new

@@ -13,17 +13,18 @@ if(File.exist?(src) && File.mtime(src) > File.mtime(f)) self.add "<%FileUtils.cp('#{src}','#{f}')%>" end } if(defined?(DEV_TASKS)) + if(DEV_TASKS[:dependencies].has_key?(:rake)) + DEV_TASKS[:dependencies][:rake].each{|rake_dir| + self.add "<%rake('#{rake_dir}')%>" if(Dir.exists?(rake_dir)) + } + end if(DEV_TASKS[:dependencies].has_key?(:source)) DEV_TASKS[:dependencies][:source].each{|source_dep| - wrk="" - parts=source_dep.split('/develop/') - wrk=parts[0].gsub("/dep/","/wrk") if parts.length > 0 - self.add "<%rake('#{wrk}')%>" if(Dir.exists?(wrk)) - + dest = "./dep/#{File.basename(source_dep)}" if(!File.exists?(dest)) self.add "<%FileUtils.cp('#{source_dep}','#{dest}')%>" else \ No newline at end of file