doctor

Types

DoctorResult = object
  name*: string
  plugin*: string
  targetOS*: set[TargetOS]
  targetFormat: set[TargetFormat]
  status*: DoctorStatus
  error*: string
  fix*: string
A working/not-working dependency check
DoctorStatus = enum
  Working, NotWorking, NotWorkingButOptional

Procs

proc display(res: DoctorResult; selected = true) {.
    ...raises: [IOError, ValueError], tags: [WriteIOEffect, ReadEnvEffect].}
proc filter(res: seq[DoctorResult]; targetOS: set[TargetOS] = {};
            targetFormat: set[TargetFormat] = {}; plugins: seq[string] = @[]): seq[
    DoctorResult] {....raises: [], tags: [].}
Return a new seq[DoctorResult] filtered by the given os, target and plugins
proc isSelected(res: DoctorResult; targetOS: set[TargetOS] = {};
                targetFormat: set[TargetFormat] = {};
                plugins: seq[string] = @[]): bool {....raises: [], tags: [].}
Return true if this DoctorResult passes the filters.
proc ok(res: DoctorResult): bool {....raises: [], tags: [].}
Return true if the item is Working
proc ok(res: seq[DoctorResult]): bool {....raises: [], tags: [].}
Return true if ALL the items are Working

Templates

template dr(res: var seq[DoctorResult]; plugin_s: string; name_s: string;
            body: untyped): untyped