mighty_repo(): Create a component repo from a spec.mighty_repo_class: Abstract parent class of all component repos. It has one property,@path: the directory holding the components, as a single non-empty string. It cannot be created directly.
Specs have the form type::path. Supported types:
local: A local directory, e.g.local::inst/examples. A spec without a prefix is treated as local.github: A GitHub repository, e.g.github::owner/repo/subdir@ref. Seemighty_repo_github().
Examples
path <- system.file("examples", package = "mighty.component")
mighty_repo(path)
#> <mighty.component::mighty_repo_local>
#> @ path: chr "/home/runner/work/_temp/Library/mighty.component/examples"
mighty_repo(paste0("local::", path))
#> <mighty.component::mighty_repo_local>
#> @ path: chr "/home/runner/work/_temp/Library/mighty.component/examples"
