A custom target's declarative configuration.
- build : Lake.NPackage pkgName → Lake.FetchM (Lake.CustomData (pkgName, name))
The target's build function.
- getJob : Lake.CustomData (pkgName, name) → Lake.BuildJob Unit
The target's resulting build job.
Instances For
Equations
- Lake.instInhabitedTargetConfig = { default := { build := default, getJob := default } }
@[inline]
def
Lake.mkTargetJobConfig
{pkgName : Lean.Name}
{α : Type}
{name : Lean.Name}
(build : Lake.NPackage pkgName → Lake.FetchM (Lake.BuildJob α))
[h : Lake.FamilyOut Lake.CustomData (pkgName, name) (Lake.BuildJob α)]
:
Lake.TargetConfig pkgName name
A smart constructor for target configurations that generate CLI targets.
Instances For
A dependently typed configuration based on its registered package and name.
- pkg : Lean.Name
- name : Lean.Name
- config : Lake.TargetConfig self.pkg self.name
Instances For
@[implemented_by Lake.OpaqueTargetConfig.unsafeGet]
opaque
Lake.OpaqueTargetConfig.get
{pkgName name : Lean.Name}
:
Lake.OpaqueTargetConfig pkgName name → Lake.TargetConfig pkgName name
unsafe def
Lake.OpaqueTargetConfig.unsafeGet
{pkgName name : Lean.Name}
:
Lake.OpaqueTargetConfig pkgName name → Lake.TargetConfig pkgName name
Instances For
unsafe def
Lake.OpaqueTargetConfig.unsafeMk
{pkgName name : Lean.Name}
:
Lake.TargetConfig pkgName name → Lake.OpaqueTargetConfig pkgName name
Instances For
instance
Lake.OpaqueTargetConfig.instInhabitedNameOfTargetConfig
{pkgName name : Lean.Name}
[Inhabited (Lake.TargetConfig pkgName name)]
:
Inhabited (Lake.OpaqueTargetConfig pkgName name)
Equations
- Lake.OpaqueTargetConfig.instInhabitedNameOfTargetConfig = { default := Lake.OpaqueTargetConfig.mk default }
instance
Lake.OpaqueTargetConfig.instCoeNameTargetConfig
{pkgName name : Lean.Name}
:
Coe (Lake.OpaqueTargetConfig pkgName name) (Lake.TargetConfig pkgName name)
Equations
- Lake.OpaqueTargetConfig.instCoeNameTargetConfig = { coe := Lake.OpaqueTargetConfig.get }
instance
Lake.OpaqueTargetConfig.instCoeTargetConfigName
{pkgName name : Lean.Name}
:
Coe (Lake.TargetConfig pkgName name) (Lake.OpaqueTargetConfig pkgName name)
@[implemented_by Lake.OpaqueTargetConfig.unsafeMk]
opaque
Lake.OpaqueTargetConfig.mk
{pkgName name : Lean.Name}
:
Lake.TargetConfig pkgName name → Lake.OpaqueTargetConfig pkgName name
def
Lake.Package.findTargetConfig?
(name : Lean.Name)
(self : Lake.Package)
:
Option (Lake.TargetConfig self.name name)
Try to find a target configuration in the package with the given name .
Equations
- Lake.Package.findTargetConfig? name self = Option.map (fun (x : Lake.OpaqueTargetConfig self.config.name name) => x.get) (Lake.DRBMap.find? self.opaqueTargetConfigs name)