Module RbConfig
In: lib/rbconfig/datadir.rb

Methods

datadir   datadir  

Public Class methods

Return the path to the data directory associated with the given package name. Normally this is just "#{RbConfig::CONFIG[‘datadir’]}/#{package_name}", but may be modified by packages like RubyGems to handle versioned data directories.

[Source]

    # File lib/rbconfig/datadir.rb, line 15
15:   def self.datadir(package_name)
16:     File.join(CONFIG['datadir'], package_name)
17:   end

Return the path to the data directory associated with the named package. If the package is loaded as a gem, return the gem specific data directory. Otherwise return a path to the share area as define by "#{ConfigMap[:datadir]}/#{package_name}".

[Source]

      # File lib/rubygems.rb, line 1095
1095: def RbConfig.datadir(package_name)
1096:   Gem.datadir(package_name) ||
1097:     File.join(Gem::ConfigMap[:datadir], package_name)
1098: end

[Validate]