acquia / lightning-project

A Composer-based installer for the Lightning distribution of Drupal 8. Support ended on November 2, 2021 and this project is no longer maintained.
133 stars 60 forks source link

Error : Repository type is not registered: github #67

Closed clauded closed 6 years ago

clauded commented 6 years ago

I'm trying to install Drupal/lightning with composer but I get the following error:

[InvalidArgumentException]                 
Repository type is not registered: github

In composer.json, the dev repo is of type "github":

 "dev": {
            "type": "github",
            "url": "https://github.com/acquia/lightning-dev",
            "no-api": true
        }
phenaproxima commented 6 years ago

It works beautifully for me; what version of Composer are you using? It might be out of date.

clauded commented 6 years ago

The version that comes with Ubuntu 16.04:

Composer version @package_branch_alias_version@ (1.0.0-beta2) 2016-03-27 16:00:34

phenaproxima commented 6 years ago

Ah, OK. That's very out of date; the current version of Composer is something like 1.6.x. It's quite possible that the github driver was introduced after 1.0.0, so I suggest updating to the latest version of Composer and trying again.

clauded commented 6 years ago

Ok. Got it working by removing the one from the distribution and installing manually a recent version. For reference if someone else encounter the error:

sudo apt remove composer
sudo apt install -y git unzip curl php-mbstring php-cli
curl -sS https://getcomposer.org/installer -o composer-setup.php
sudo php composer-setup.php --install-dir=/usr/bin --filename=composer

Thanks for the help.

phenaproxima commented 6 years ago

You're quite welcome. Glad you got it working :)

balsama commented 6 years ago

Related: #68