Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for OS Platforms 2019 #31

Closed
leogdion opened this issue Apr 17, 2020 · 6 comments
Closed

Support for OS Platforms 2019 #31

leogdion opened this issue Apr 17, 2020 · 6 comments

Comments

@leogdion
Copy link
Contributor

running Komondor give me:

Package.swift:8:21: error: 'v13' is unavailable
  platforms: [.iOS(.v13), .macOS(.v10_15), .watchOS(.v6)],
                    ^~~
PackageDescription.SupportedPlatform:28:27: note: 'v13' was introduced in PackageDescription 5.1
        public static var v13: PackageDescription.SupportedPlatform.IOSVersion
                          ^
Package.swift:8:35: error: 'v10_15' is unavailable
  platforms: [.iOS(.v13), .macOS(.v10_15), .watchOS(.v6)],
                                  ^~~~~~
PackageDescription.SupportedPlatform:9:27: note: 'v10_15' was introduced in PackageDescription 5.1
        public static var v10_15: PackageDescription.SupportedPlatform.MacOSVersion
                          ^
Package.swift:8:54: error: 'v6' is unavailable
  platforms: [.iOS(.v13), .macOS(.v10_15), .watchOS(.v6)],
                                                     ^~
PackageDescription.SupportedPlatform:37:27: note: 'v6' was introduced in PackageDescription 5.1
        public static var v6: PackageDescription.SupportedPlatform.WatchOSVersion
                          ^
Fatal error: Error raised at top level: PackageConfig.Error(reason: "Could not find a file at /var/folders/6k/_f1dpksd0nq047ybxl941y_m0000gn/T/package-config - something went wrong with compilation step probably"): file /AppleInternal/BuildRoot/Library/Caches/com.apple.xbs/Sources/swiftlang/swiftlang-1103.8.25.8/swift/stdlib/public/core/ErrorType.swift, line 200
swift -v

Apple Swift version 5.2.2 (swiftlang-1103.0.32.6 clang-1103.0.32.51)
Target: x86_64-apple-darwin19.4.0
/Applications/Xcode.app/Contents/Developer/usr/bin/lldb "--repl=-enable-objc-interop -stack-check -sdk /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -color-diagnostics"
Welcome to Apple Swift version 5.2.2 (swiftlang-1103.0.32.6 clang-1103.0.32.51).
Type :help for assistance.

Package.swift:

// swift-tools-version:5.2
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription

let package = Package(
  name: "HeartwitchKit",
  platforms: [.iOS(.v13), .macOS(.v10_15), .watchOS(.v6)],
  products: [
    // Products define the executables and libraries produced by a package, and make them visible to other packages.
    .library(
      name: "HeartwitchKit",
      targets: ["HeartwitchKit"]
    )
  ],
  dependencies: [
    // Dependencies declare other packages that this package depends on.
    // .package(url: /* package url */, from: "1.0.0"),
    .package(url: "https://github.com/shibapm/Komondor.git", from: "1.0.0")
  ],
  targets: [
    // Targets are the basic building blocks of a package. A target can define a module or a test suite.
    // Targets can depend on other targets in this package, and on products in packages which this package depends on.
    .target(
      name: "HeartwitchKit",
      dependencies: []
    ),
    .testTarget(
      name: "HeartwitchKitTests",
      dependencies: ["HeartwitchKit"]
    )
  ]
)

#if canImport(PackageConfig)
  import PackageConfig

  let config = PackageConfiguration([
    "komondor": [
      "pre-push": ["swift test"],
      "pre-commit": [
        "swift test",
        "pod spec lint",
        "swiftlint autocorrect && swiftformat .",
        "swiftformat --lint . && swiftlint",
        "git add ."
      ]
    ]
  ]).write()
#endif
@orta
Copy link
Member

orta commented Apr 17, 2020

Sure, we'd accept PRs for this - maybe it's picking up the wrong tools version to parse

@leogdion
Copy link
Contributor Author

yep I started a fork to look into it.

Could it be with:
https://github.com/shibapm/PackageConfig

... and not necessarily with this repo?

@orta
Copy link
Member

orta commented Apr 17, 2020

Yeah, that sounds reasonable to me

@leogdion
Copy link
Contributor Author

Added a fix with a pull-request

@leogdion
Copy link
Contributor Author

Fix for Komondor #34

@leogdion
Copy link
Contributor Author

fixed in #34 release 1.0.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants