(argv: CliArguments)
| 143 | } |
| 144 | |
| 145 | function normalizeAliases(argv: CliArguments): void { |
| 146 | const aliases = argv as CliArguments & { |
| 147 | apiKey?: string; |
| 148 | outputDir?: string; |
| 149 | outputFormat?: string; |
| 150 | }; |
| 151 | |
| 152 | argv.apikey = aliases.apiKey ?? argv.apikey; |
| 153 | argv.outputdir = aliases.outputDir ?? argv.outputdir; |
| 154 | argv.format = aliases.outputFormat ?? argv.format; |
| 155 | } |
| 156 | |
| 157 | function getApiError(error: Error): { message?: string; code?: string } | undefined { |
| 158 | const maybeResponse = error as Error & { |