Dub.getLatestVersion

Returns the latest available version for a particular package.

This function returns the latest numbered version of a package. If no numbered versions are available, it will return an available branch, preferring "~master".

  1. Version getLatestVersion(PackageName name, bool prefer_stable)
    class Dub
    getLatestVersion
    (,
    bool prefer_stable = true
    )
  2. Version getLatestVersion(string name, bool prefer_stable)

Parameters

name PackageName

The name of the package in question.

prefer_stable bool

If set to true (the default), returns the latest stable version, even if there are newer pre-release versions.

See Also

listPackageVersions

Meta