简体   繁体   中英

zsh: command not found: get-graphql-schema

I'm trying to download my graphcms schema into my flutter project. I'm using Ferry as the graphql client.

According to the ferry docs I just need to run npm install -g get-graphql-schema and then run get-graphql-schema [ENDPOINT_URL] > lib/schema.graphql to download the schema.

However, when I try running that command, I get this in the terminal: zsh: command not found: get-graphql-schema .

I'm using an m1 mac - not sure if this is an m1-specific issue.

Any ideas on how to solve this would be much appreciated.

You must remove the apollo-cli by command:

brew uninstall apollo-cli

And try run get-graphql-schema [ENDPOINT_URL] > lib/schema.graphql again. In my case, it's successfully.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM