我正在尝试让作曲家从这个项目中下载以下库,但是,它没有composer.json
文件,所以我不确定这是否可行。
{
"require" : {
"fguillot/picoFeed" : "*"
},
"repositories": [
{
"type": "vcs",
"url": "https://github.com/fguillot/picoFeed"
}
]
}
错误:
[作曲\库\ InvalidRepositoryException]
在任何分支或标记中都找不到有效的composer.json https://github.com/fguillot/picoFeed,无法加载包 从它。
答案 0 :(得分:68)
要包含非作曲家存储库,您需要设置package repository。这会给你类似的东西:
{
"repositories": [
{
"type": "package",
"package": {
"name": "fguillot/picoFeed",
"version": "dev-master",
"source": {
"url": "https://github.com/fguillot/picoFeed",
"type": "git",
"reference": "origin/master"
}
}
}
],
"require": {
"fguillot/picoFeed": "dev-master"
}
}