File tree Expand file tree Collapse file tree
packages/apollo/src/commands/service Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import { flags } from "@oclif/command" ;
22import { introspectionFromSchema } from "graphql" ;
33import { writeFileSync } from "fs" ;
4+ import chalk from "chalk" ;
45import { ProjectCommand } from "../../Command" ;
56
67export default class ServiceDownload extends ProjectCommand {
@@ -45,9 +46,16 @@ export default class ServiceDownload extends ProjectCommand {
4546 ) ;
4647 } catch ( e ) {
4748 if ( e . code == "ECONNREFUSED" ) {
48- console . error (
49- `❌ ERROR: Connection refused. You may not be running a service locally, or your endpoint url is incorrect.\n` +
49+ this . log ( chalk . red ( "ERROR: Connection refused." ) ) ;
50+ this . log (
51+ chalk . red (
52+ "You may not be running a service locally, or your endpoint url is incorrect."
53+ )
54+ ) ;
55+ this . log (
56+ chalk . red (
5057 "If you're trying to download a schema from Apollo Engine, use the `client:download-schema` command instead."
58+ )
5159 ) ;
5260 }
5361 throw e ;
You can’t perform that action at this time.
0 commit comments