MCPcopy Index your code
hub / github.com/SoCreate/angular-playground / run

Function run

projects/cli/src/run.ts:10–55  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

8import { checkSnapshots } from './check-snapshots';
9
10export async function run() {
11 const config: Config = configure(process.argv);
12
13 try {
14 await buildSandboxes(config.sourceRoots, config.chunk, config.verifySandboxes || config.checkVisualRegressions, config.definedSandboxesPath);
15 } catch (err) {
16 throw err;
17 }
18
19 if (config.build || config.buildWithServiceWorker) {
20 return await buildAngularCli(config.angularAppName, !!config.buildWithServiceWorker, config.baseHref, config.angularCliMaxBuffer);
21 }
22
23 if (config.verifySandboxes || (config.checkVisualRegressions && !config.deleteSnapshots)) {
24 config.angularCliPort = await getPort({host: config.angularCliHost});
25 }
26
27 if ((config.watch && !config.deleteSnapshots) || config.verifySandboxes || (config.checkVisualRegressions && !config.deleteSnapshots)) {
28 startWatch(config.sourceRoots, () =>
29 buildSandboxes(config.sourceRoots, config.chunk, config.verifySandboxes || config.checkVisualRegressions, config.definedSandboxesPath));
30 }
31
32 if ((config.serve && !config.deleteSnapshots) || config.verifySandboxes || (config.checkVisualRegressions && !config.deleteSnapshots)) {
33 try {
34 await serveAngularCli(config);
35 } catch (err) {
36 throw err;
37 }
38 }
39
40 if (config.verifySandboxes) {
41 try {
42 await verifySandboxes(config);
43 } catch (err) {
44 throw err;
45 }
46 }
47
48 if (config.checkVisualRegressions) {
49 try {
50 await checkSnapshots(config);
51 } catch (err) {
52 throw err;
53 }
54 }
55}

Callers 1

index.tsFile · 0.90

Calls 7

configureFunction · 0.90
buildSandboxesFunction · 0.90
buildAngularCliFunction · 0.90
startWatchFunction · 0.90
serveAngularCliFunction · 0.90
verifySandboxesFunction · 0.90
checkSnapshotsFunction · 0.90

Tested by

no test coverage detected