MCPcopy Create free account
hub / github.com/Devographics/Monorepo / parseCliConfig

Function parseCliConfig

capture/src/cli.ts:4–23  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2import { getConfig } from './config'
3
4export const parseCliConfig = async () => {
5 const args = process.argv
6 const resultsPath = args[2]
7 if (!resultsPath) {
8 logger.error(`no survey results path provided`)
9 await flushLogs()
10 process.exit(1)
11 }
12
13 const outputDir = args[3]
14 if (!outputDir) {
15 logger.error(`no output directory provided`)
16 await flushLogs()
17 process.exit(1)
18 }
19
20 const startFromLocale = args[4]
21
22 return getConfig(resultsPath, outputDir, startFromLocale)
23}

Callers 2

mosaicFunction · 0.90
captureFunction · 0.90

Calls 2

flushLogsFunction · 0.90
getConfigFunction · 0.90

Tested by

no test coverage detected