Sha256: eb4da5eba0a37f3bee1796b11288b81b8c1c49f67f4a534a46af2c8239baa4ba
Contents?: true
Size: 795 Bytes
Versions: 112
Compression:
Stored size: 795 Bytes
Contents
require 'rbconfig' require 'find' require 'ftools' include Config # this was adapted from rdoc's install.rb by ways of Log4r $sitedir = CONFIG["sitelibdir"] unless $sitedir version = CONFIG["MAJOR"] + "." + CONFIG["MINOR"] $libdir = File.join(CONFIG["libdir"], "ruby", version) $sitedir = $:.find {|x| x =~ /site_ruby/ } if !$sitedir $sitedir = File.join($libdir, "site_ruby") elsif $sitedir !~ Regexp.quote(version) $sitedir = File.join($sitedir, version) end end # the acual gruntwork Dir.chdir("lib") Find.find("composite_primary_keys", "composite_primary_keys.rb") { |f| if f[-3..-1] == ".rb" File::install(f, File.join($sitedir, *f.split(/\//)), 0644, true) else File::makedirs(File.join($sitedir, *f.split(/\//))) end }
Version data entries
112 entries across 112 versions & 4 rubygems