Skip to content

swift_package_pin

Synthetic locked Swift package identity.

Description

swift_package_pin is emitted by swift_package_dependencies. It makes the external package graph visible through the same typed graph and query surfaces as first-party targets. Users should not declare it directly.

Each pin records the package identity, source location, locked state, checkout location, and dependencies on other pins. Source-control packages retain versions, revisions, and branches. Registry packages also retain their checksum. Local packages use a local identity suffix.

Attributes

AttributeTypeRequiredDescription
identitystringyesCanonical lowercase Swift package identity
package_namestringnoPackage display name from the resolved graph
source_kindstringnoremoteSourceControl, registry, or localSourceControl
locationstringnoRegistry, source-control, or local package location
versionstringnoLocked semantic version
revisionstringnoLocked source-control revision
branchstringnoLocked source-control branch
checksumstringnoLocked registry checksum
checkout_pathstringnoWorkspace-relative checkout path reported by Swift Package Manager

Dependency edges

EdgeAcceptsDescription
depsswift_package_pinLocked transitive package dependencies

Providers

The target emits swift_package_pin. Its provider repeats the lock identity and lists the identities of its direct package dependencies.

Capabilities

CapabilityOutput groups
buildnone

The target has no build action. Compilation is owned by the corresponding swift_package_dependencies target.

Upstream contract

The fields follow Swift Package Manager's ResolvedPackagesStore model.

Released under an open-source license.