Module: Config

Defined in:
lib/minigems/core.rb

Class Method Summary collapse

Class Method Details

.datadir(package_name) ⇒ Object

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 “#:datadir/#package_name”.



307
308
309
310
# File 'lib/minigems/core.rb', line 307

def datadir(package_name)
  Gem.datadir(package_name) ||
    File.join(Gem::ConfigMap[:datadir], package_name)
end