From ac33aabeb50bc8024c8d941f39a513fd4ca8be61 Mon Sep 17 00:00:00 2001 From: Firdavs Khaydarov Date: Sat, 3 Feb 2024 22:41:44 +0200 Subject: [PATCH 1/2] Added visionOS support --- Package.swift | 4 ---- Package@swift-5.9.swift | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+), 4 deletions(-) create mode 100644 Package@swift-5.9.swift diff --git a/Package.swift b/Package.swift index 6b61308..d198b35 100644 --- a/Package.swift +++ b/Package.swift @@ -1,5 +1,4 @@ // swift-tools-version: 5.7 -// The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription @@ -12,7 +11,6 @@ let package = Package( .watchOS("6.0") ], products: [ - // Products define the executables and libraries a package produces, and make them visible to other packages. .library( name: "OpenAI", targets: ["OpenAI"] @@ -22,8 +20,6 @@ let package = Package( .package(url: "https://github.com/Recouse/EventSource.git", from: "0.0.7") ], 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 this package depends on. .target( name: "OpenAI", dependencies: [ diff --git a/Package@swift-5.9.swift b/Package@swift-5.9.swift new file mode 100644 index 0000000..4477e93 --- /dev/null +++ b/Package@swift-5.9.swift @@ -0,0 +1,35 @@ +// swift-tools-version: 5.9 + +import PackageDescription + +let package = Package( + name: "OpenAI", + platforms: [ + .macOS("10.15"), + .iOS("13.0"), + .tvOS("13.0"), + .watchOS("6.0"), + .visionOS("1.0") + ], + products: [ + .library( + name: "OpenAI", + targets: ["OpenAI"] + ) + ], + dependencies: [ + .package(url: "https://github.com/Recouse/EventSource.git", from: "0.0.7") + ], + targets: [ + .target( + name: "OpenAI", + dependencies: [ + .product(name: "EventSource", package: "EventSource") + ] + ), + .testTarget( + name: "OpenAITests", + dependencies: ["OpenAI"] + ) + ] +) From 531677ad5749d4129dbace2a7f58d011376d21bd Mon Sep 17 00:00:00 2001 From: Firdavs Khaydarov Date: Sat, 3 Feb 2024 22:42:53 +0200 Subject: [PATCH 2/2] Updated README with information about visionOS support --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index a41f93e..8f27333 100644 --- a/README.md +++ b/README.md @@ -78,6 +78,7 @@ for try await chunk in chat { * iOS 13.0+ * tvOS 13.0+ * watchOS 6.0+ +* visionOS 1.0+ ## Dependencies