我是npm的noob,作曲家和咕噜声。这是我的第一个项目,我正在整合grunt,composer和npm。这是项目中的composer.json
文件:
{
"name": "company/project",
"description": "HTML5 and CSS3 Template",
"type": "project",
"keywords": [
"keyword with three",
"keyword two",
"keyword"
],
"homepage": "https://company.com/project",
"license": "GPL-2.0+",
"authors": [
{
"name": "Mayeenul Islam",
"email": "me@example.com",
"homepage": "http://example.com",
"role": "Designer and Developer"
}
],
"archive": {
"exclude": [
".gitignore",
"*.sublime-workspace",
"*.sublime-project",
"composer.json",
"composer.lock",
"README.md",
"Gruntfile.js",
"package.json",
"/node_modules",
"/tests",
"!/vendor"
]
},
"scripts": {
"post-install-cmd": "npm install",
"pre-archive-cmd": "composer install"
}
}
我有效package.json
和Gruntfile.js
。我希望我的项目的协作者只需克隆我的repo,然后运行composer install
并加载插件依赖项,并执行npm install
以便可以准备好grunt环境。
注意:我无法使用
composer.lock
和composer install
在Windows 8 PC中制作任何composer update
文件。
但是,在克隆了repo之后,当我正在运行composer install
时,它正在加载作曲家的东西,但没有运行npm install
中定义的"post-install-cmd"
。我之后尝试运行composer update
,但它也无效。
我做错了什么?