Images and publishing
Swift package registry
Answer SwiftPM as a package registry over a git host. Each version tag is fetched once, kept and scanned.
- Settings, Registries: switch on Swift package registry.
- Add a Swift registry. Its address is a git host, like
https://github.com. - Write Swift rules: pattern
apple.swift-logorapple.*, versions1.6.1,^1.6.0or>=1.6 <2. - Developers point SwiftPM at
/swift/. See Set up SwiftPM.
- A package is a repository.
apple.swift-logisgithub.com/apple/swift-log. Its tags that are versions, like 1.6.1 or v1.6.1, are its releases. - The tag list comes from git itself, not the GitHub API, so there is no API rate limit.
- ForgeRepo™ fetches the tag archive once, keeps and scans it, and gives SwiftPM its checksum. A tag moved later on the git host changes nothing here.
- While it resolves, SwiftPM reads the manifest of several allowed versions, not only the one it picks. Each of those archives is fetched and kept too, because the manifest and the checksum come from it.
- The release list holds only allowed versions. A package with none allowed is refused with the reason, and that opens a request.
- Advisories come from OSV, which knows Swift packages by their GitHub url. Malware scanning, the kill switch, auto approve and Cache now all work.
- Package.swift names no license, so Swift packages have none on record.
swift package-registry publishis refused. This registry mirrors packages.