0

I am using composer to install packages from my own private github account.

Right now, if I want to include any particular package from my github, every time I need to add new entry in composer.json under the repositories key, like this:

"repositories": [
    {
        "type": "vcs",
        "url": "git@github.com:VendorNamespace/GitHubRepository1.git",
        "no-api": true
    },
    {
        "type": "vcs",
        "url": "git@github.com:VendorNamespace/GitHubRepository2.git",
        "no-api": true
    },
    .
    .
    .
    {
        "type": "vcs",
        "url": "git@github.com:VendorNamespace/GitHubRepository100.git",
        "no-api": true
    }
]

Instead of doing so, I would like composer to recognize that using VendorNamespace as the vendor part of a package points to particular GitHub account and not repeating the above entry for every particular package I want to include.

Jacek Dziurdzikowski
  • 2,015
  • 2
  • 13
  • 20

1 Answers1

2

You can't do this, unfortunatelly.

One solution would be to use Private Packagist, or to boot up your own instance of packagist.org site which is open source: https://github.com/composer/packagist, which would then host your own private packages.

Edi Modrić
  • 2,240
  • 1
  • 15
  • 18