我确实配置了一个位桶存储库composer.json,但composer正在用git文件夹克隆整个存储库及其分支。
如何获取刚刚选定的分支?
{
"repositories": [
{
"type": "package",
"package": {
"name": "greenweb/framework",
"source": {
"url": "https://bitbucket.org/my_team/my_framework.git",
"type": "git",
"reference": "origin/develop"
},
"version": "1.0.0"
}
}
],
"require": {
"php": ">=5.4.0",
"greenweb/framework": "*"
}
}
调整composer.json
:
{
"repositories": [
{
"type": "vcs",
"url": "git@bitbucket.org/my_team/my_framework.git"
}
],
"require": {
"php": ">=5.4.0",
"greenweb/framework": "dev-develop"
}
}
然后运行:
$ composer install
有关参考,请参见https://getcomposer.org/doc/05-repositories.md#using-私人存储库。