Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

  • Parameters

    • Optional configOrConfigFetcher: MakerDebConfig | ((arch: string) => MakerDebConfig)

      Either a configuration object for this maker or a simple method that returns such a configuration for a given target architecture

    • Optional platformsToMakeOn: string[]

      If you want this maker to run on platforms different from defaultPlatforms you can provide those platforms here

    Returns MakerDeb

Properties

defaultPlatforms: string[] = ...
name: string = 'deb'
requiredExternalBinaries: string[] = ...

Accessors

  • get platforms(): string[]
  • Returns string[]

Methods

  • ensureDirectory(dir: string): Promise<void>
  • Ensures the directory exists and is forced to be empty.

    I.e. If the directory already exists it is deleted and recreated, this is a destructive operation

    Parameters

    • dir: string

    Returns Promise<void>

  • ensureExternalBinariesExist(): void
  • Throws an error if any of the binaries don't exist.

    Returns void

  • ensureFile(file: string): Promise<void>
  • Ensures the path to the file exists and the file does not exist

    I.e. If the file already exists it is deleted and the path created

    Parameters

    • file: string

    Returns Promise<void>

  • externalBinariesExist(): boolean
  • Checks if the specified binaries exist, which are required for the maker to be used.

    Returns boolean

  • isInstalled(module: string): boolean
  • Checks if the given module is installed, used for testing if optional dependencies are installed or not

    Parameters

    • module: string

    Returns boolean

  • isSupportedOnCurrentPlatform(): boolean
  • Makers must implement this method and return true or false indicating whether this maker can be run on the current platform. Normally this is just a process.platform check but it can be a deeper check for dependencies like fake-root or other required external build tools.

    If the issue is a missing dependency you should log out a HELPFUL error message telling the developer exactly what is missing and if possible how to get it.

    Returns boolean

  • normalizeWindowsVersion(version: string): string
  • Normalize the given semver-formatted version to a 4-part dot delimited version number without prerelease information for use in Windows apps.

    Parameters

    • version: string

    Returns string

  • prepareConfig(targetArch: string): Promise<void>
  • Parameters

    • targetArch: string

    Returns Promise<void>