From e2d0353090011bed8c394fefca058eee0818875a Mon Sep 17 00:00:00 2001 From: "Sven A. Schmidt" Date: Fri, 29 Apr 2022 16:26:25 +0200 Subject: [PATCH] Add docc support --- .spi.yml | 4 +++- Package.resolved | 16 ++++++++++++++++ Package.swift | 9 ++++++++- 3 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 Package.resolved diff --git a/.spi.yml b/.spi.yml index 3adffc4..a4415f3 100644 --- a/.spi.yml +++ b/.spi.yml @@ -1,5 +1,7 @@ version: 1 builder: configs: + - platform: macos-spm + documentation_target: SemanticVersion - platform: watchos - scheme: SemanticVersion-watchOS + scheme: SemanticVersion-watchOS diff --git a/Package.resolved b/Package.resolved new file mode 100644 index 0000000..3b6d58b --- /dev/null +++ b/Package.resolved @@ -0,0 +1,16 @@ +{ + "object": { + "pins": [ + { + "package": "SwiftDocCPlugin", + "repositoryURL": "https://github.com/apple/swift-docc-plugin", + "state": { + "branch": null, + "revision": "3303b164430d9a7055ba484c8ead67a52f7b74f6", + "version": "1.0.0" + } + } + ] + }, + "version": 1 +} diff --git a/Package.swift b/Package.swift index adcb606..6bdd3a4 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:4.2 +// swift-tools-version:5.3 // Copyright 2020-2021 Dave Verwer, Sven A. Schmidt, and other contributors. // @@ -29,3 +29,10 @@ let package = Package( .testTarget(name: "SemanticVersionTests", dependencies: ["SemanticVersion"]), ] ) + +#if swift(>=5.6) +// Add the documentation compiler plugin if possible +package.dependencies.append( + .package(url: "https://github.com/apple/swift-docc-plugin", from: "1.0.0") +) +#endif