Sha256: c583bc19e3b3c2433385261831f05dae37337e25ba6a4e26c71a2d08301eac9e

Contents?: true

Size: 789 Bytes

Versions: 9

Compression:

Stored size: 789 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("dr_nic_magic_models", "dr_nic_magic_models.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

9 entries across 9 versions & 2 rubygems

Version Path
voraz-dr_nic_magic_models-0.9.2 install.rb
voraz-dr_nic_magic_models-0.9.3 install.rb
dr_nic_magic_models-0.8.1 install.rb
dr_nic_magic_models-0.9.1 install.rb
dr_nic_magic_models-0.7.1 install.rb
dr_nic_magic_models-0.9.2 install.rb
dr_nic_magic_models-0.7.0 install.rb
dr_nic_magic_models-0.9.0 install.rb
dr_nic_magic_models-0.8.0 install.rb