MCPcopy Create free account
hub / github.com/di-sukharev/opencommit / normalizePlatform

Function normalizePlatform

out/cli.cjs:70023–70042  ·  view source on GitHub ↗
(platform)

Source from the content-addressed store, hash-verified

70021 if (arch2 === "arm")
70022 return "arm";
70023 if (arch2 === "aarch64" || arch2 === "arm64")
70024 return "arm64";
70025 if (arch2)
70026 return `other:${arch2}`;
70027 return "unknown";
70028};
70029var normalizePlatform = (platform) => {
70030 platform = platform.toLowerCase();
70031 if (platform.includes("ios"))
70032 return "iOS";
70033 if (platform === "android")
70034 return "Android";
70035 if (platform === "darwin")
70036 return "MacOS";
70037 if (platform === "win32")
70038 return "Windows";
70039 if (platform === "freebsd")
70040 return "FreeBSD";
70041 if (platform === "openbsd")
70042 return "OpenBSD";
70043 if (platform === "linux")
70044 return "Linux";
70045 if (platform)

Callers 1

getPlatformPropertiesFunction · 0.85

Calls 2

toLowerCaseMethod · 0.80
includesMethod · 0.80

Tested by

no test coverage detected