Magento 2 extension loading procedure has been significantly changed in the first week of October 2015.
Now, as I understand, a module (extension) must have a registration.php
file.
If a module has no registration.php
file then the module will not be loaded.
An example of registration.php
file: https://github.com/magento/magento2/blob/develop/app/code/Magento/Catalog/registration.php
I use the same registration.php
code for all my extensions:
<?php
use Magento\Framework\Component\ComponentRegistrar;
$name = implode('_', array_map(function($part) {
return implode(array_map('ucfirst', explode('-', $part)));
}, array_slice(explode(DIRECTORY_SEPARATOR, __DIR__), -2, 2)));
ComponentRegistrar::register(ComponentRegistrar::MODULE, $name, __DIR__);