ameenross/magento_packager

A tool to package Magento 1 extensions for Magento Connect.

v0.2.0 2016-12-28 16:54 UTC

This package is auto-updated.

Last update: 2024-10-24 05:13:13 UTC


README

Latest Stable Version Total Downloads Latest Unstable Version License

A tool to package Magento 1 extensions for Magento Connect.

Rationale

Packaging extensions for Magento 1 is an old-fashioned and cumbersome process of logging into the backend of a Magento installation, where the extension must be installed. Then one has to fill in a large form for every single release, even though most of the data usually doesn't change at all. Also, you have to manually add the files that comprise your package...

What madness! Let's automate the packaging process with a script that's as easy to install and use as any other Composer package! Enter MagentoPackager.

Installation

composer require ameenross/magento_packager

Usage

  1. Create a file called magepkg.xml in your extension directory, make sure the metadata corresponds to your package:
<?xml version="1.0"?>
<package>
    <name>My Extension</name>
    <version/>
    <stability>stable</stability>
    <license uri="https://opensource.org/licenses/GPL-3.0">GPL-3.0</license>
    <channel>community</channel>
    <extends/>
    <summary>This is a short description of My Extension.</summary>
    <description>
        This is a longer description of the functionality of My Extension.
        It does many things.
    </description>
    <notes/>
    <authors>
        <author>
            <name>Me</name>
            <user>me</user>
            <email>me@example.com</email>
        </author>
    </authors>
    <date/>
    <time/>
    <contents/>
    <compatible/>
    <dependencies>
        <required>
            <php>
                <min>5.4.0</min>
                <max>6.0.0</max>
            </php>
        </required>
    </dependencies>
</package>
  1. Invoke the CLI script. It needs to be fed a TAR archive containing your extension. It also needs to be told where to store the resulting package (if not in the current working directory), its version and any release notes. Example:
git archive HEAD | vendor/bin/magepkg -o releases/ --version="1.0.0" --notes="First stable release."