openclaw/apps/shared/ClawdbotKit/Package.swift
Frederic Haddad de0665ab8b fix(macos): complete Clawd → Molt rename in Swift code and build scripts
Fix incomplete rename that broke macOS app builds:

- Update Package.swift to use ClawdbotKit package identifier (SPM uses path name)
- Fix argument order in ClawdbotKit Package.swift (dependencies before path)
- Add path properties to macos Package.swift targets pointing to Clawdbot* directories
- Update notification name references (.clawdbotSelectSettingsTab → .moltbotSelectSettingsTab)
- Update CommandResolver method calls (clawdbotCommand → moltbotCommand, etc.)
- Update self.clawdbotOAuthDirEnv → self.moltbotOAuthDirEnv
- Fix resource paths in package-mac-app.sh (Sources/Moltbot → Sources/Clawdbot)
- Fix icon filename reference (Moltbot.icns → Clawdbot.icns)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 23:24:19 +04:00

62 lines
2.0 KiB
Swift

// swift-tools-version: 6.2
import PackageDescription
let package = Package(
name: "MoltbotKit",
platforms: [
.iOS(.v18),
.macOS(.v15),
],
products: [
.library(name: "MoltbotProtocol", targets: ["MoltbotProtocol"]),
.library(name: "MoltbotKit", targets: ["MoltbotKit"]),
.library(name: "MoltbotChatUI", targets: ["MoltbotChatUI"]),
],
dependencies: [
.package(url: "https://github.com/steipete/ElevenLabsKit", exact: "0.1.0"),
.package(url: "https://github.com/gonzalezreal/textual", exact: "0.3.1"),
],
targets: [
.target(
name: "MoltbotProtocol",
path: "Sources/ClawdbotProtocol",
swiftSettings: [
.enableUpcomingFeature("StrictConcurrency"),
]),
.target(
name: "MoltbotKit",
dependencies: [
"MoltbotProtocol",
.product(name: "ElevenLabsKit", package: "ElevenLabsKit"),
],
path: "Sources/ClawdbotKit",
resources: [
.process("Resources"),
],
swiftSettings: [
.enableUpcomingFeature("StrictConcurrency"),
]),
.target(
name: "MoltbotChatUI",
dependencies: [
"MoltbotKit",
.product(
name: "Textual",
package: "textual",
condition: .when(platforms: [.macOS, .iOS])),
],
path: "Sources/ClawdbotChatUI",
swiftSettings: [
.enableUpcomingFeature("StrictConcurrency"),
]),
.testTarget(
name: "MoltbotKitTests",
dependencies: ["MoltbotKit", "MoltbotChatUI"],
path: "Tests/ClawdbotKitTests",
swiftSettings: [
.enableUpcomingFeature("StrictConcurrency"),
.enableExperimentalFeature("SwiftTesting"),
]),
])