graphcool:找不到命令(本地 Mac)

graphcool: command not found (locally on Mac)

我正在我的 Mac 上本地安装 graphcool,我认为一切正常:

$ sudo npm install -g graphcool
npm WARN deprecated jsonstream@1.0.3: use JSONStream instead
npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
/usr/local/bin/graphcool-framework -> /usr/local/lib/node_modules/graphcool/dist/index.js
/usr/local/bin/gcf -> /usr/local/lib/node_modules/graphcool/dist/index.js
+ graphcool@0.11.4
updated 1 package in 7.251s

但是 graphcool 似乎没有被识别:

$ graphcool init server
-bash: graphcool: command not found

我从 graphcool init 得到同样的错误。

谁能帮帮我?

似乎他们将二进制名称从 graphcool 更改为 graphcool-frameworkgcf

https://github.com/graphcool/framework/commit/5de2334440c55f6a42f6d75ad1b06a8d320d5e40

尝试:

graphcool-framework init

如果您收到 "no such file or directory, lstat '~/.graphcool'" 的错误消息,请执行

touch ~/.graphcool

然后重新输入上面的初始化命令

我设置graphcool的顺序是:

npm install -g graphcool-framework
mkdir ~/.graphcool
cd .graphcool
touch config.yml
graphcool-framework init server