staempfli/composer-installer

一个简单的composer安装程序

这个包的规范存储库似乎已经不存在,因此该包已被冻结。

安装次数: 2,485

依赖者: 0

建议者: 0

安全性: 0

星星: 0

关注者: 7

分支: 0

开放问题: 0

类型:composer-installer

0.1.4 2016-04-20 08:12 UTC

This package is auto-updated.

Last update: 2020-09-15 17:59:43 UTC


README

基于AOEpeople/composer-installers的Magento Composer安装程序

描述

这个Composer安装程序是AOEpeople/composer-installers的修改版本,以便满足我们在部署我们的Magento项目时的需求。

修改

它已经提供了我们需要的路径位置,因此不需要在项目的composer文件中进行额外配置。

protected $locations = array(
    'module'    => 'magento/.modman/{$name}/',
    'source'    => 'magento/'
);

它通过在删除目录之前备份当前的magento安装来处理magento版本的升级,因此不会丢失数据,并在需要时可以恢复。

    if($package->getType() === 'magento-source') {
        $installPath    = $this->getInstallPath($package);
        $backupDate     = date('YmdHi');
        $backupPath     = $installPath . '_' . $backupDate;

        $this->filesystem->copyThenRemove($installPath, $backupPath);
        $this->io->write(sprintf('Backup %s - %s', $backupPath, is_dir($backupPath) ? '<comment>created</comment>' : '<error>not created</error>'));
    } else {
        $repo->removePackage($package);
        $installPath = $this->getInstallPath($package);
        $this->io->write(sprintf('Deleting %s - %s', $installPath, $this->filesystem->removeDirectory($installPath) ? '<comment>deleted</comment>' : '<error>not deleted</error>'));
    }

支持

如果您对这个扩展有任何问题,请在GitHub上提交问题。

贡献

任何贡献都备受赞赏。最佳贡献代码的方式是在GitHub上提交一个拉取请求。

开发者

Staempfli Webteam和所有其他贡献者

许可

GNU通用公共许可证,版本3(GPLv3)

版权

(c) 2015, Stämpfli AG