lib/rbbt/resource/util.rb in rbbt-util-5.37.13 vs lib/rbbt/resource/util.rb in rbbt-util-5.37.14
- old
+ new
@@ -43,10 +43,10 @@
self.byte(0) == SLASH || (self.byte(0) == DOT && self.byte(1) == SLASH) || (resource != Rbbt && (Open.remote?(self) || Open.ssh?(self)))
end
end
module Resource
- def set_software_env(software_dir)
+ def set_software_env(software_dir = self.root.software)
software_dir.opt.find_all.collect{|d| d.annotate(File.dirname(d)) }.reverse.each do |software_dir|
next unless software_dir.exists?
software_dir = File.expand_path(software_dir)
opt_dir = File.join(software_dir, 'opt')
bin_dir = File.join(opt_dir, 'bin')