Last active
May 7, 2026 14:12
-
-
Save kkebo/4a930605b1f2fb744efdb5abd6908511 to your computer and use it in GitHub Desktop.
AppleProductTypes in Swift Playgrounds 4.1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // From /Applications/Playgrounds.app/Contents/Toolchain/usr/lib/swift/pm/ManifestAPI/AppleProductTypes.swiftmodule/arm64-apple-ios-macabi.swiftinterface | |
| // swift-interface-format-version: 1.0 | |
| // swift-compiler-version: Apple Swift version 5.6 (swiftlang-5.6.0.323.62 clang-1316.0.20.8) | |
| // swift-module-flags: -target arm64-apple-ios13.4-macabi -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -package-description-version 999.0 -module-link-name AppleProductTypes -module-name AppleProductTypes | |
| // swift-module-flags-ignorable: -user-module-version 15 | |
| import PackageDescription | |
| import Swift | |
| extension PackageDescription.Product { | |
| public static func iOSApplication( | |
| name: Swift.String, | |
| targets: [Swift.String], | |
| bundleIdentifier: Swift.String? = nil, | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| iconAssetName: Swift.String? = nil, | |
| accentColorAssetName: Swift.String? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product | |
| @available(_PackageDescription 5.6) | |
| public static func iOSApplication( | |
| name: Swift.String, | |
| targets: [Swift.String], | |
| bundleIdentifier: Swift.String? = nil, | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| appIcon: PackageDescription.ProductSetting.IOSAppInfo.AppIcon? = nil, | |
| accentColor: PackageDescription.ProductSetting.IOSAppInfo.AccentColor? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| appCategory: PackageDescription.ProductSetting.IOSAppInfo.AppCategory? = nil, | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // swift-interface-format-version: 1.0 | |
| // swift-compiler-version: Apple Swift version 5.6 (swiftlang-5.6.0.323.62 clang-1316.0.20.8) | |
| // swift-module-flags: -target arm64-apple-ios14.7 -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -package-description-version 999.0 -module-link-name AppleProductTypes -module-name AppleProductTypes | |
| // swift-module-flags-ignorable: -user-module-version 15 | |
| import PackageDescription | |
| import Swift | |
| extension PackageDescription.Product { | |
| public static func iOSApplication( | |
| name: Swift.String, | |
| targets: [Swift.String], | |
| bundleIdentifier: Swift.String? = nil, | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| iconAssetName: Swift.String? = nil, | |
| accentColorAssetName: Swift.String? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product | |
| @available(_PackageDescription 5.6) | |
| public static func iOSApplication( | |
| name: Swift.String, | |
| targets: [Swift.String], | |
| bundleIdentifier: Swift.String? = nil, | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| appIcon: PackageDescription.ProductSetting.IOSAppInfo.AppIcon? = nil, | |
| accentColor: PackageDescription.ProductSetting.IOSAppInfo.AccentColor? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| appCategory: PackageDescription.ProductSetting.IOSAppInfo.AppCategory? = nil, | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // From /Applications/Xcode.app/Contents/PlugIns/IDESwiftPackageCore.framework/Versions/A/Frameworks/SwiftPM.framework/SharedSupport/ManifestAPI/AppleProductTypes.swiftmodule/armor-apple-macos.swiftinterface | |
| // swift-interface-format-version: 1.0 | |
| // swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12) | |
| // swift-module-flags: -target arm64-apple-macos11.0 -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -package-description-version 999.0 -module-link-name AppleProductTypes -module-name AppleProductTypes | |
| // swift-module-flags-ignorable: -user-module-version 20504 | |
| import PackageDescription | |
| import Swift | |
| extension PackageDescription.Product { | |
| public static func iOSApplication( | |
| name: Swift.String, | |
| targets: [Swift.String], | |
| bundleIdentifier: Swift.String? = nil, | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| iconAssetName: Swift.String? = nil, | |
| accentColorAssetName: Swift.String? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product | |
| @available(_PackageDescription 5.6) | |
| public static func iOSApplication( | |
| name: Swift.String, | |
| targets: [Swift.String], | |
| bundleIdentifier: Swift.String? = nil, | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| appIcon: PackageDescription.ProductSetting.IOSAppInfo.AppIcon? = nil, | |
| accentColor: PackageDescription.ProductSetting.IOSAppInfo.AccentColor? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| appCategory: PackageDescription.ProductSetting.IOSAppInfo.AppCategory? = nil, | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Run this on Swift Playground's Xcode Playground | |
| import Foundation | |
| import UIKit | |
| print(Bundle.main.bundlePath) | |
| let appPath = sequence(first: Bundle.main.bundleURL) { current in | |
| let parent = current.deletingLastPathComponent() | |
| return parent.path == current.path ? nil : parent | |
| } | |
| .first { $0.pathExtension == "app" }! | |
| .path | |
| print(appPath) | |
| let iter = FileManager.default.enumerator(atPath: appPath)! | |
| let maxDepth = 1 | |
| for case let path as String in iter { | |
| // print(path) | |
| if iter.level >= maxDepth { | |
| iter.skipDescendants() | |
| } | |
| } | |
| UIPasteboard.general.string = try! String(contentsOfFile: appPath + "/Developer/Toolchains/Toolchain/usr/lib/swift/pm/ManifestAPI/AppleProductTypes.swiftmodule/arm64-apple-ios.swiftinterface", encoding: .utf8) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- old 2022-05-22 18:24:26.098324171 +0900 | |
| +++ new 2022-05-22 18:24:31.859007183 +0900 | |
| @@ -5,10 +5,11 @@ | |
| teamIdentifier: Swift.String? = nil, | |
| displayVersion: Swift.String? = nil, | |
| bundleVersion: Swift.String? = nil, | |
| - iconAssetName: Swift.String? = nil, | |
| - accentColorAssetName: Swift.String? = nil, | |
| + appIcon: PackageDescription.ProductSetting.IOSAppInfo.AppIcon? = nil, | |
| + accentColor: PackageDescription.ProductSetting.IOSAppInfo.AccentColor? = nil, | |
| supportedDeviceFamilies: [PackageDescription.ProductSetting.IOSAppInfo.DeviceFamily], | |
| supportedInterfaceOrientations: [PackageDescription.ProductSetting.IOSAppInfo.InterfaceOrientation], | |
| capabilities: [PackageDescription.ProductSetting.IOSAppInfo.Capability] = [], | |
| + appCategory: PackageDescription.ProductSetting.IOSAppInfo.AppCategory? = nil, | |
| additionalInfoPlistContentFilePath: Swift.String? = nil | |
| ) -> PackageDescription.Product |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- mac.swift 2022-05-22 19:13:50.074693735 +0900 | |
| +++ ios.swift 2022-05-22 19:13:19.180145742 +0900 | |
| @@ -1,7 +1,7 @@ | |
| // swift-interface-format-version: 1.0 | |
| -// swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12) | |
| -// swift-module-flags: -target arm64-apple-macos11.0 -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -package-description-version 999.0 -module-link-name AppleProductTypes -module-name AppleProductTypes | |
| -// swift-module-flags-ignorable: -user-module-version 20504 | |
| +// swift-compiler-version: Apple Swift version 5.6 (swiftlang-5.6.0.323.62 clang-1316.0.20.8) | |
| +// swift-module-flags: -target arm64-apple-ios14.7 -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -package-description-version 999.0 -module-link-name AppleProductTypes -module-name AppleProductTypes | |
| +// swift-module-flags-ignorable: -user-module-version 15 | |
| import PackageDescription | |
| import Swift | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment