ameenross / magento_packager
用于为 Magento Connect 打包 Magento 1 扩展的工具。
v0.2.0
2016-12-28 16:54 UTC
Requires
- php: ^5.4.0|^7.0.0
- pear/archive_tar: ^1.4
Requires (Dev)
- apigen/apigen: ^4.1
- squizlabs/php_codesniffer: ^2.7
This package is auto-updated.
Last update: 2024-09-24 05:00:14 UTC
README
用于为 Magento Connect 打包 Magento 1 扩展的工具。
理由
为 Magento 1 打包扩展是一个过时的、繁琐的过程,需要登录到扩展必须安装的 Magento 安装的后端。然后,对于每个版本,都必须填写一个大型表单,尽管大部分数据通常根本不会改变。此外,你还需要手动添加组成你的包的文件...
多么疯狂!让我们通过一个像其他 Composer 包一样容易安装和使用的脚本来自动化打包过程!欢迎 MagentoPackager。
安装
composer require ameenross/magento_packager
使用方法
- 在你的扩展目录中创建一个名为
magepkg.xml
的文件,确保元数据与你的包相匹配
<?xml version="1.0"?> <package> <name>My Extension</name> <version/> <stability>stable</stability> <license uri="https://open-source.org.cn/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>
- 调用 CLI 脚本。它需要一个包含你的扩展的 TAR 存档。它还需要知道将结果包存储在哪里(如果不在当前工作目录),以及版本和任何发行说明。示例
git archive HEAD | vendor/bin/magepkg -o releases/ --version="1.0.0" --notes="First stable release."