Skip to content


Repository files navigation

🚢 Releases

Using Releases you can easily resolve all released versions from a Git repository, in either a Swift script or command line tool. It supports both remote & local repositories and provides convenience APIs for sorting, filtering out pre-released versions, etc.


Simply call Releases.versions(for: url) and you'll get an array of Version back:

let url = URL(string: "")!
let releases = Releases.versions(for: url)

// Print the latest version

Remove all pre-release versions (like Alpha, Beta, etc):

let url = URL(string: "!
let releases = Releases.versions(for: url).withoutPreReleases()

// Print the latest stable version


  • Add .package(url: "", from: "5.0.0") to your Package.swift file's dependencies.
  • Update your packages using $ swift package update.

Help, feedback or suggestions?