This is just a quick preview of the likely experience for extension developers who wish to list their extensions (or themes) on the new Magento Connect (TNMC). A part of this is describing how the Magento 2 installation wizard interacts with Composer. Official documentation is coming – this post is just to give a super quick overview to demistify what is going to be involved.
For Extension Developers
Firstly, all extensions listed on TNMC will be uploaded (for M2) as a set of Composer packages in ZIP format. That is, you create a ZIP file for each module of the directory where the composer.json file is (the root of your module directory).
If your extension consists of multiple modules, you upload one package per module.
One “root” package will be uploaded with associated “extension” metadata for including in the store. (E.g. extension description, price, etc.) You don’t have to repeat this for each module in a multi-module extension.
Composer packages have version numbers. If you need to release a patch, you create a new ZIP for the new version and upload that.
To Install for First Time
You will be able to use composer to create a new project from scratch, but it will be a bit slow. Because of this, we are considering having a pre-built ZIP or tar ball of a base CE installation which you then upgrade as required to newer patch levels.
To Install an Extension
To install an extension, you can use the installation wizard. There is a section called “component manager”. This connects to the Composer repo and downloads the “packages.json” file. It uses this to tell you what you have installed or not installed. It will let you update modules.
CE and EE will be shipped as a metapackage pointing at all the modules to include. The component manager knows this, and will display the parent metapackage with packages (if there is one). (Later this might turn into an expand/collapse tree view.)
Extensions will likely be recommended to do the same if you have more than one package – create a parent metapackage, if only because it helps the component manager know the packages that form the extension.
If you purchase an extension, it will be added to the packages.json file for your account. Using component manager you can add a dependency to the new composer package (with correspondeing) composer.json file and download the extension using Composer.
In summary, creating Composer packages for a working module is to basically ZIP the directory tree up.
The installation experience using the instllation wizard will be controlled by a packages.json file retrieved by Composer. But it is basically using Composer tools.
More details are coming. Until then, hopefully this post answers a few questions.