メインコンテンツへスキップ
macOSコンパニオンアプリの インスタンス UI は、Appleモデル識別子をわかりやすい名前にマッピングします(iPad16,6 -> “iPad Pro 13-inch (M4)“、Mac16,6 -> “MacBook Pro (14-inch, 2024)”)。DeviceModelCatalog は識別子のプレフィックス(デバイスファミリーへのフォールバックあり)も使用して、デバイスごとに SF Symbol を選択します。 apps/macos/Sources/OpenClaw/Resources/DeviceModels/ 内のファイル:
ファイル目的
ios-device-identifiers.jsoniOS/iPadOS 識別子 -> 名前のマッピング
mac-device-identifiers.jsonMac 識別子 -> 名前のマッピング
NOTICE.md固定されたアップストリームのコミットSHA
LICENSE.apple-device-identifiers.txtアップストリームの MIT ライセンス

データソース

MITライセンスの kyle-seongwoo-jun/apple-device-identifiers GitHub リポジトリからベンダリングされています。JSONファイルは、ビルドの決定性を保つために NOTICE.md に記録されたコミットSHAに固定されています。

データベースの更新

  1. 固定するアップストリームのコミットSHAを選びます(iOS用に1つ、macOS用に1つ)。
  2. apps/macos/Sources/OpenClaw/Resources/DeviceModels/NOTICE.md を新しいSHAで更新します。
  3. それらのコミットに固定されたJSONファイルを再ダウンロードします:
IOS_COMMIT="<commit sha for ios-device-identifiers.json>"
MAC_COMMIT="<commit sha for mac-device-identifiers.json>"

curl -fsSL "https://raw.githubusercontent.com/kyle-seongwoo-jun/apple-device-identifiers/${IOS_COMMIT}/ios-device-identifiers.json" \
  -o apps/macos/Sources/OpenClaw/Resources/DeviceModels/ios-device-identifiers.json

curl -fsSL "https://raw.githubusercontent.com/kyle-seongwoo-jun/apple-device-identifiers/${MAC_COMMIT}/mac-device-identifiers.json" \
  -o apps/macos/Sources/OpenClaw/Resources/DeviceModels/mac-device-identifiers.json
  1. LICENSE.apple-device-identifiers.txt が引き続きアップストリームと一致していることを確認します。アップストリームのライセンスが変更されている場合は置き換えます。
  2. macOSアプリが問題なくビルドされることを確認します:
swift build --package-path apps/macos

関連