After spending many hours crafting the perfect Magento module you need to package it either for easy distribution to your client/team or to upload to Magento Connect.
Package the extension
First of all I would recommend reading the following wiki page;
Note - If your planning to upload your module to Magento Connect ensure the package name and the name you enter on Magento Connect match
Installing a module from a local package
Internally Magento uses a localised and enhanced version of Pear to manage packages and to distribute and install extensions. Since version 1.4.* the internal pear script has been renamed to mage. In order to use the mage script to run any of the commands it provides you first need to ensure that the executable bit is set for your user.
1
| |
Once your user has permission to execute this script you can run it without any arguments to see a full list of commands;
1
| |
This will list all of the available commands. You can use this script to install remote extensions from Magento Connect or to install local packages such as the one you have just built. To install the local package you need to use the following command, changing the path and package name for the extension to the location of your files.
1
| |
Thats it your done⦠Or at least you should be. If you are testing the package in the version of Magento you used to build the package remember to remove the original files first or you will get a bunch of errors. The error output is generally very helpful, simply do what is suggested and try the install again.
