File tree Expand file tree Collapse file tree
packages/apollo/src/commands/client Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,9 +19,7 @@ export default class SchemaDownload extends ClientCommand {
1919 static args = [
2020 {
2121 name : "output" ,
22- description : "Path to write the introspection result to" ,
23- required : true ,
24- default : "schema.json"
22+ description : "Path to write the introspection result to"
2523 }
2624 ] ;
2725
@@ -30,7 +28,9 @@ export default class SchemaDownload extends ClientCommand {
3028 let gitContext ;
3129 await this . runTasks ( ( { args, project, flags } ) => {
3230 const isSDLFormat = flags . target && flags . target . toUpperCase ( ) === "SDL" ;
33- const output = isSDLFormat ? "schema.graphql" : args . output ;
31+ console . log ( args ) ;
32+ const output =
33+ args . output || ( isSDLFormat ? "schema.graphql" : "schema.json" ) ;
3434 return [
3535 {
3636 title : `Saving schema to ${ output } ` ,
You can’t perform that action at this time.
0 commit comments