MCPcopy
hub / github.com/ionic-team/capacitor / runTask

Function runTask

cli/src/common.ts:212–224  ·  view source on GitHub ↗
(title: string, fn: () => Promise<T>)

Source from the content-addressed store, hash-verified

210}
211
212export async function runTask<T>(title: string, fn: () => Promise<T>): Promise<T> {
213 const chain = output.createTaskChain();
214 chain.next(title);
215
216 try {
217 const value = await fn();
218 chain.end();
219 return value;
220 } catch (e) {
221 chain.fail();
222 throw e;
223 }
224}
225
226export async function getCapacitorPackage(config: Config, name: string): Promise<PackageJson | null> {
227 const packagePath = resolveNode(config.app.rootDir, `@capacitor/${name}`, 'package.json');

Callers 15

getPluginsTaskFunction · 0.90
runAndroidFunction · 0.90
addAndroidFunction · 0.90
buildAndroidFunction · 0.90
signWithApkSignerFunction · 0.90
signWithJarSignerFunction · 0.90
installCocoaPodsPluginsFunction · 0.90
getPluginsTaskFunction · 0.90
runIOSFunction · 0.90
addIOSFunction · 0.90
buildiOSFunction · 0.90
copyFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected