MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / getMdmConfigPath

Method getMdmConfigPath

src/services/mdm/MdmService.ts:143–164  ·  view source on GitHub ↗

* Get the platform-specific MDM configuration file path

()

Source from the content-addressed store, hash-verified

141 * Get the platform-specific MDM configuration file path
142 */
143 private getMdmConfigPath(): string {
144 const platform = os.platform()
145 const isProduction = getClerkBaseUrl() === PRODUCTION_CLERK_BASE_URL
146 const configFileName = isProduction ? "mdm.json" : "mdm.dev.json"
147
148 switch (platform) {
149 case "win32": {
150 // Windows: %ProgramData%\RooCode\mdm.json or mdm.dev.json
151 const programData = process.env.PROGRAMDATA || "C:\\ProgramData"
152 return path.join(programData, "RooCode", configFileName)
153 }
154
155 case "darwin":
156 // macOS: /Library/Application Support/RooCode/mdm.json or mdm.dev.json
157 return `/Library/Application Support/RooCode/${configFileName}`
158
159 case "linux":
160 default:
161 // Linux: /etc/roo-code/mdm.json or mdm.dev.json
162 return `/etc/roo-code/${configFileName}`
163 }
164 }
165
166 /**
167 * Get the singleton instance

Callers 1

loadMdmConfigMethod · 0.95

Calls 1

getClerkBaseUrlFunction · 0.90

Tested by

no test coverage detected