const mixinafFpm::Repository
afFpm::Repository
A repository of pods; usually a local directory or a fanr repository.
Repository classes are instantiated by FpmConfig.
- cleanUp
abstract Void cleanUp()Cleans up any cached information this repository may hold.
- delete
abstract Void delete(PodFile podFile)Deletes the given pod.
- download
abstract File download(PodFile podFile)Returns a file representation of the given pod.
- dump
abstract Str dump()- isDirRepo
Bool isDirRepo()Returns
trueif this repository is just a single directory of pods.- isFanrRepo
abstract Bool isFanrRepo()Returns
trueif this repository is backed by fanr.- isLocal
abstract Bool isLocal()Returns
trueif this repository is local / hosted on the file system.- isRemote
Bool isRemote()Returns
trueif this repository is remote / hosted on the Internet.- makeDirRepo
static new makeDirRepo(File dir)Creates a local directory repository for the given directory.
- makeFanrRepo
static new makeFanrRepo(Uri url, Str? username := null, Str? password := null)Creates a fanr repository (local or remote) for the given URL.
- name
abstract Str name()Name of the repository.
- resolve
abstract PodFile[] resolve(Depend depend, Str:Obj? options)Returns a list of all
PodFilesthat match the given dependency.Options are targeted at remote fanr repositories and may include:
maxPods (Int)- the maximum number of pods to return. (defaults to 5).corePods (Bool)- also query for core pods.minVer (Version)- the min pod version to query for.log (Log)- query results will be logged to this.
- resolveAll
abstract PodFile[] resolveAll()Returns the latest version of all pods this repository holds.
- upload
abstract PodFile upload(PodFile podFile)Installs the given pod. Returns the newly installed
PodFile.- url
abstract Uri url()URL of where the repository is located.