RPC and API
डिवाइस मॉडल डेटाबेस
macOS साथी ऐप इंस्टेंसेस UI में Apple मॉडल पहचानकर्ताओं (जैसे iPad16,6, Mac16,6) को मनुष्यों द्वारा पढ़े जा सकने वाले नामों से मैप करके अनुकूल Apple डिवाइस मॉडल नाम दिखाता है।
मैपिंग JSON के रूप में यहां वेंडर की गई है:
apps/macos/Sources/OpenClaw/Resources/DeviceModels/
डेटा स्रोत
हम वर्तमान में MIT-लाइसेंस वाले रिपॉज़िटरी से मैपिंग वेंडर करते हैं:
kyle-seongwoo-jun/apple-device-identifiers
बिल्ड को निर्धारक बनाए रखने के लिए, JSON फ़ाइलों को विशिष्ट upstream कमिट्स पर पिन किया गया है (जो apps/macos/Sources/OpenClaw/Resources/DeviceModels/NOTICE.md में दर्ज हैं)।
डेटाबेस अपडेट करना
- वे upstream कमिट्स चुनें जिन्हें आप पिन करना चाहते हैं (एक iOS के लिए, एक macOS के लिए)।
apps/macos/Sources/OpenClaw/Resources/DeviceModels/NOTICE.mdमें कमिट हैश अपडेट करें।- उन कमिट्स पर पिन की गई 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- सुनिश्चित करें कि
apps/macos/Sources/OpenClaw/Resources/DeviceModels/LICENSE.apple-device-identifiers.txtअब भी upstream से मेल खाता है (यदि upstream लाइसेंस बदलता है तो इसे बदल दें)। - सत्यापित करें कि macOS ऐप साफ़ तौर पर बिल्ड होता है (कोई चेतावनी नहीं):
swift build --package-path apps/macosसंबंधित
Was this useful?