How To Load Composer Packages from a VCS Repo

Another TIL short tip, this time on composer syntax for loading a custom package (or a non-registered package, or whatever the case may be) from version control.

So, I'm building a Formstack API extension for the marvelous Bolt CMS, and I decided to use Josh Gulledge's FormStackAPI PHP integration.

The thing with Bolt CMS is that it uses its own (Satis) package repository for Composer, and it disables the use of the standard repos. This means packages must be loaded from the Bolt marketplace, or else manually via a repositories entry.

So I have the choice to either include the package source in my repo, or link to it via a special vcs repository setting in composer.json. I chose the latter.

"repositories": {
  "fstackapi_php-git-repo": {

Original tip posted at

Jul 02, 2022