MCPcopy Index your code
hub / github.com/callstack/agent-device / readAndroidDevPrefs

Function readAndroidDevPrefs

src/daemon/runtime-hints.ts:104–112  ·  view source on GitHub ↗
(device: DeviceInfo, packageName: string)

Source from the content-addressed store, hash-verified

102}
103
104async function readAndroidDevPrefs(device: DeviceInfo, packageName: string): Promise<string> {
105 const result = await runAndroidAdb(
106 device,
107 ['shell', 'run-as', packageName, 'cat', ANDROID_DEV_PREFS_PATH],
108 { allowFailure: true },
109 );
110 if (result.exitCode !== 0) return DEFAULT_ANDROID_PREFS_XML;
111 return normalizeAndroidPrefsXml(result.stdout);
112}
113
114async function writeAndroidDevPrefs(
115 device: DeviceInfo,

Callers 2

applyAndroidRuntimeHintsFunction · 0.85
clearAndroidRuntimeHintsFunction · 0.85

Calls 2

runAndroidAdbFunction · 0.90
normalizeAndroidPrefsXmlFunction · 0.85

Tested by

no test coverage detected