class Yoda::Store::Actions::ImportCoreLibrary
Attributes
registry[R]
@return [Registry]
Public Class Methods
new(registry)
click to toggle source
@param registry [Registry]
# File lib/yoda/store/actions/import_core_library.rb, line 16 def initialize(registry) @registry = registry end
run(registry)
click to toggle source
@return [true, false]
# File lib/yoda/store/actions/import_core_library.rb, line 10 def run(registry) new(registry).run end
Public Instance Methods
run()
click to toggle source
@return [true, false]
# File lib/yoda/store/actions/import_core_library.rb, line 21 def run return false unless File.exist?(doc_path) patch = YardImporter.import(doc_path) registry.add_patch(patch) true end
Private Instance Methods
doc_path()
click to toggle source
# File lib/yoda/store/actions/import_core_library.rb, line 30 def doc_path File.expand_path("~/.yoda/sources/ruby-#{RUBY_VERSION}/.yardoc") end