()
| 4 | import { Runner, TypescriptStarterArgsOptions, validateName } from './utils'; |
| 5 | |
| 6 | export async function checkArgs(): Promise<TypescriptStarterArgsOptions> { |
| 7 | const cli = meow( |
| 8 | ` |
| 9 | Usage |
| 10 | $ npx typescript-starter |
| 11 | |
| 12 | Non-Interactive Usage |
| 13 | $ npx typescript-starter <project-name> [options] |
| 14 | |
| 15 | Options |
| 16 | --appveyor include Appveyor for Windows CI |
| 17 | --description, -d package.json description |
| 18 | --dom include DOM type definitions |
| 19 | --node include node.js type definitions |
| 20 | --strict enable stricter type-checking |
| 21 | --travis include Travis CI configuration |
| 22 | --yarn use yarn (default: npm) |
| 23 | |
| 24 | --no-circleci don't include CircleCI |
| 25 | --no-cspell don't include cspell |
| 26 | --no-editorconfig don't include .editorconfig |
| 27 | --no-functional don't enable eslint-plugin-functional |
| 28 | --no-install skip yarn/npm install |
| 29 | --no-vscode don't include VS Code debugging config |
| 30 | |
| 31 | Non-Interactive Example |
| 32 | $ npx typescript-starter my-library -d 'do something, better' |
| 33 | `, |
| 34 | { |
| 35 | flags: { |
| 36 | appveyor: { |
| 37 | default: false, |
| 38 | type: 'boolean', |
| 39 | }, |
| 40 | circleci: { |
| 41 | default: true, |
| 42 | type: 'boolean', |
| 43 | }, |
| 44 | cspell: { |
| 45 | default: true, |
| 46 | type: 'boolean', |
| 47 | }, |
| 48 | description: { |
| 49 | alias: 'd', |
| 50 | default: 'a typescript-starter project', |
| 51 | type: 'string', |
| 52 | }, |
| 53 | dom: { |
| 54 | default: false, |
| 55 | type: 'boolean', |
| 56 | }, |
| 57 | editorconfig: { |
| 58 | default: true, |
| 59 | type: 'boolean', |
| 60 | }, |
| 61 | functional: { |
| 62 | default: true, |
| 63 | type: 'boolean', |
no test coverage detected