class Gem::Specification

def doc_dir type = nil

def doc_dir type = nil
  @doc_dir ||= File.join base_dir, 'doc', full_name
  if type then
    File.join @doc_dir, type
  else
    @doc_dir
  end
end