npm后安装失败与多个命令

在我的composer.json里面,有一个像下面这样的postinstall挂接安装程序:

 "scripts" : { "dist" : "node dist; node_modules/.bin/doccoh src/package.js", "postinstall" : "node_modules/.bin/grunt setup || true; node_modules/.bin/bower install", "start" : "node server.js" } 

每当我运行它(从Git / Gnu Bash CLI获胜),我结束

command not found. either the command was written wrong or couldn't be found

德语CLI错误的粗略翻译。

我试图分裂成多个; /分号分隔的部分,并首先进入该目录的cd ,但它只是结束了相同的错误信息。 用一个简单的ls代替整个postinstall命令集可以工作。 所以我这个问题可能是分号分隔或命令的错误使用。 但总的来说,我不知道什么是错的。

注意:我在全球安装了grunt-cli 0.1.9版和grunt 0.4.1版。

我有点晚回答,但如果你在Windows上,单行上的多个命令是使用&&执行的

 postinstall: "some command && some other -c" 

我遇到了这个东西,并认为这可能会帮助其他人。 我发现移动到postinstall.js文件变得容易一些,因为事情变得有点复杂。 这使得处理前进更容易。