Sharing code across Package manifests

We have a codebase with many local Swift Packages in a single repository. In order to better keep dependency URLs and versions synced across all of the Package.swift files, it would be beneficial if we could do something like this:

// global file
extension Package.Dependency {
  static let nuke = .package(name: "Nuke", url: ..., .upToNextMinor(...))
  static let apollo = ...
}
// Package.swift A
let package = Package(..., dependencies: [.nuke, .apollo])
// Package.swift B
let package = Package(..., dependencies: [.apollo])

is this possible in any way?

Terms of Service

Privacy Policy

Cookie Policy