Composer stuck on installing private GitHub repos

I was trying to install some GitHub repos as dependencies using composer. Composer kept getting stuck on installing the private ones.


    "repositories": [
            "type": "vcs",
            "url": ""
    "require-dev": {
        "inderpreet99/private": "1.0.1"


$ composer install
Loading composer repositories with package information

The "" file could not be downloaded (HTTP/1.1 404 Not Found)

install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress] [--no-suggest] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--ignore-platform-reqs] [--] []...


  1. Go to your GitHub profile.
  2. Under Developer Settings > Personal access tokens, generate a new token.
  3. In cli:
    $ export GITHUB_ACCESS_TOKEN="gibberisheaab78ab18285b9something"
    $ composer config -g $GITHUB_ACCESS_TOKEN

Composer should work much more smoothly now.

Leave a Comment