INNER CODE UNIT · Python
sdk_path
viticci/shortcuts-playground-plugin · claude/skills/shortcuts-playground/scripts/generate_healthkit_reference.py:146
def sdk_path() -> Path:
raw = subprocess.check_output(["xcrun", "--sdk", "iphoneos", "--show-sdk-path"], text=True)
return Path(raw.strip())
def actionkit_units() -> list[dict[str, object]]:
if not ACTIONKIT_HEALTH_CONSTANTS.exists():
return []
try:
with ACTIONKIT_HEALTH_CONSTANTS.open("rb") as handle:
payload = plistlib.load(handle)
except (OSError, plistlib.InvalidFileException):
return []
units = payload.get("Units")
if not isinstance(units, list):
return []
out: list[dict[str, object]] = []
for row in units: