supergraphql/graphql-cli-prepare

View on GitHub
src/index.ts

Summary

Maintainability
A
0 mins
Test Coverage
Missing semicolon
import { Prepare } from './prepare'
Missing semicolon
import { CommandBuilder } from 'yargs'
 
const command: {
command: string
describe?: string
handler: (context: any, argv: any) => any
builder?: CommandBuilder
} = {
command: 'prepare',
describe: 'Bundle schemas and generate bindings',
 
builder: {
output: {
alias: 'o',
describe: 'Output folder',
type: 'string'
},
save: {
alias: 's',
describe: 'Save settings to config file',
type: 'boolean',
default: 'false'
},
bundle: {
describe: 'Process schema imports',
type: 'boolean',
default: 'false'
},
bindings: {
describe: 'Generate bindings',
type: 'boolean',
default: 'false'
},
generator: {
alias: 'g',
describe: 'Generator used to generate bindings',
type: 'string'
},
verbose: {
describe: 'Show verbose output messages',
type: 'boolean',
default: 'false'
}
},
 
handler: async (context: any, argv) => {
if (!argv.bundle && !argv.bindings) {
Missing semicolon
argv.bundle = argv.bindings = true
}
 
Missing semicolon
const prepare = new Prepare(context, argv)
Missing semicolon
await prepare.handle()
}
Missing semicolon
}
 
Missing semicolon
export = command