Skip to content

Commit

Permalink
Merge pull request #23 from nanasess/4.1.1-4.1.2
Browse files Browse the repository at this point in the history
4.1.2用の更新
  • Loading branch information
chihiro-adachi authored Feb 21, 2022
2 parents 450d633 + 4ed93d5 commit 4b686cc
Show file tree
Hide file tree
Showing 16 changed files with 2,951 additions and 23,031 deletions.
4 changes: 2 additions & 2 deletions Command/DumpAutoloadCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* file that was distributed with this source code.
*/

namespace Plugin\EccubeUpdater410to411\Command;
namespace Plugin\EccubeUpdater411to412\Command;

use Eccube\Service\Composer\ComposerApiService;
use Symfony\Component\Console\Command\Command;
Expand All @@ -22,7 +22,7 @@

class DumpAutoloadCommand extends Command
{
protected static $defaultName = 'eccube:update410to411:dump-autoload';
protected static $defaultName = 'eccube:update411to412:dump-autoload';

/**
* @var ContainerInterface
Expand Down
4 changes: 2 additions & 2 deletions Command/PluginAlreadyInstalledCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* file that was distributed with this source code.
*/

namespace Plugin\EccubeUpdater410to411\Command;
namespace Plugin\EccubeUpdater411to412\Command;

use Doctrine\ORM\NonUniqueResultException;
use Doctrine\ORM\NoResultException;
Expand All @@ -28,7 +28,7 @@

class PluginAlreadyInstalledCommand extends Command
{
protected static $defaultName = 'eccube:update410to411:plugin-already-installed';
protected static $defaultName = 'eccube:update411to412:plugin-already-installed';

/**
* @var ContainerInterface
Expand Down
4 changes: 2 additions & 2 deletions Command/UpdatePreInstallPluginsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* file that was distributed with this source code.
*/

namespace Plugin\EccubeUpdater410to411\Command;
namespace Plugin\EccubeUpdater411to412\Command;

use Eccube\Repository\BaseInfoRepository;
use Eccube\Repository\PluginRepository;
Expand All @@ -24,7 +24,7 @@

class UpdatePreInstallPluginsCommand extends Command
{
protected static $defaultName = 'eccube:update410to411:update-pre-install-plugins';
protected static $defaultName = 'eccube:update411to412:update-pre-install-plugins';

/**
* @var ContainerInterface
Expand Down
8 changes: 4 additions & 4 deletions Common/Constant.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@
* file that was distributed with this source code.
*/

namespace Plugin\EccubeUpdater410to411\Common;
namespace Plugin\EccubeUpdater411to412\Common;

class Constant
{
const FROM_VERSION = '4.1.0';
const TO_VERSION = '4.1.1';
const PLUGIN_CODE = 'EccubeUpdater410to411';
const FROM_VERSION = '4.1.1';
const TO_VERSION = '4.1.2';
const PLUGIN_CODE = 'EccubeUpdater411to412';
}
38 changes: 19 additions & 19 deletions Controller/Admin/ConfigController.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* file that was distributed with this source code.
*/

namespace Plugin\EccubeUpdater410to411\Controller\Admin;
namespace Plugin\EccubeUpdater411to412\Controller\Admin;

use Doctrine\ORM\NonUniqueResultException;
use Doctrine\ORM\NoResultException;
Expand All @@ -25,7 +25,7 @@
use Eccube\Service\PluginApiService;
use Eccube\Service\SystemService;
use Eccube\Util\CacheUtil;
use Plugin\EccubeUpdater410to411\Common\Constant as UpdaterConstant;
use Plugin\EccubeUpdater411to412\Common\Constant as UpdaterConstant;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Template;
use Symfony\Component\Filesystem\Filesystem;
use Symfony\Component\Finder\Finder;
Expand Down Expand Up @@ -107,8 +107,8 @@ public function __construct(
}

/**
* @Route("/%eccube_admin_route%/eccube_updater_410_to_411/config", name="eccube_updater410to411_admin_config")
* @Template("@EccubeUpdater410to411/admin/config.twig")
* @Route("/%eccube_admin_route%/eccube_updater_411_to_412/config", name="eccube_updater411to412_admin_config")
* @Template("@EccubeUpdater411to412/admin/config.twig")
*/
public function index(Request $request)
{
Expand Down Expand Up @@ -156,8 +156,8 @@ public function index(Request $request)
/**
* プラグインのEC-CUBE対応バージョンのチェックを行う.
*
* @Route("/%eccube_admin_route%/eccube_updater_410_to_411/check_plugin_version", name="eccube_updater410to411_admin_check_plugin_version")
* @Template("@EccubeUpdater410to411/admin/check_plugin_vesrion.twig")
* @Route("/%eccube_admin_route%/eccube_updater_411_to_412/check_plugin_version", name="eccube_updater411to412_admin_check_plugin_version")
* @Template("@EccubeUpdater411to412/admin/check_plugin_vesrion.twig")
*/
public function checkPluginVersion(Request $request)
{
Expand Down Expand Up @@ -185,8 +185,8 @@ public function checkPluginVersion(Request $request)
/**
* ファイルの書き込み権限チェックを行う.
*
* @Route("/%eccube_admin_route%/eccube_updater_410_to_411/check_permission", name="eccube_updater410to411_admin_check_permission", methods={"POST"})
* @Template("@EccubeUpdater410to411/admin/check_permission.twig")
* @Route("/%eccube_admin_route%/eccube_updater_411_to_412/check_permission", name="eccube_updater411to412_admin_check_permission", methods={"POST"})
* @Template("@EccubeUpdater411to412/admin/check_permission.twig")
*/
public function checkPermission(Request $request, Filesystem $fs)
{
Expand Down Expand Up @@ -238,8 +238,8 @@ public function checkPermission(Request $request, Filesystem $fs)
/**
* 更新ファイルの競合を確認する.
*
* @Route("/%eccube_admin_route%/eccube_updater_410_to_411/check_source", name="eccube_updater410to411_admin_check_source", methods={"POST"})
* @Template("@EccubeUpdater410to411/admin/check_source.twig")
* @Route("/%eccube_admin_route%/eccube_updater_411_to_412/check_source", name="eccube_updater411to412_admin_check_source", methods={"POST"})
* @Template("@EccubeUpdater411to412/admin/check_source.twig")
*/
public function checkSource(Request $request)
{
Expand Down Expand Up @@ -295,7 +295,7 @@ public function checkSource(Request $request)
/**
* ファイルを上書きする.
*
* @Route("/%eccube_admin_route%/eccube_updater_410_to_411/update_files", name="eccube_updater410to411_admin_update_files", methods={"POST"})
* @Route("/%eccube_admin_route%/eccube_updater_411_to_412/update_files", name="eccube_updater411to412_admin_update_files", methods={"POST"})
*/
public function updateFiles(Request $request, CacheUtil $cacheUtil)
{
Expand All @@ -305,7 +305,7 @@ public function updateFiles(Request $request, CacheUtil $cacheUtil)

$this->systemService->switchMaintenance(true);
$phpPath = $this->getPhpPath();
$completeUrl = $this->generateUrl('eccube_updater410to411_admin_complete', [], UrlGeneratorInterface::ABSOLUTE_URL);
$completeUrl = $this->generateUrl('eccube_updater411to412_admin_complete', [], UrlGeneratorInterface::ABSOLUTE_URL);

$this->clearComposerCache();
$this->clearProxies();
Expand All @@ -326,14 +326,14 @@ public function updateFiles(Request $request, CacheUtil $cacheUtil)
$commands = [
'cache:clear --no-warmup',
'cache:warmup --no-optional-warmers',
'eccube:update410to411:plugin-already-installed',
'eccube:update411to412:plugin-already-installed',
'eccube:generate:proxies',
'doctrine:schema:update --dump-sql -f',
'doctrine:migrations:migrate --no-interaction',
'eccube:update410to411:update-pre-install-plugins',
'eccube:update411to412:update-pre-install-plugins',
'cache:clear --no-warmup',
'cache:warmup --no-optional-warmers',
'eccube:update410to411:dump-autoload',
'eccube:update411to412:dump-autoload',
];

log_info('Start update commands');
Expand Down Expand Up @@ -373,8 +373,8 @@ public function updateFiles(Request $request, CacheUtil $cacheUtil)
/**
* 完了画面を表示.
*
* @Route("/%eccube_admin_route%/eccube_updater_410_to_411/complete", name="eccube_updater410to411_admin_complete")
* @Template("@EccubeUpdater410to411/admin/complete.twig")
* @Route("/%eccube_admin_route%/eccube_updater_411_to_412/complete", name="eccube_updater411to412_admin_complete")
* @Template("@EccubeUpdater411to412/admin/complete.twig")
*/
public function complete(CacheUtil $cacheUtil)
{
Expand Down Expand Up @@ -461,13 +461,13 @@ private function forceClearCaches()
* phpの実行パスを返す
*
* 実行パスはPhpExecutableFinderで自動探索を行います。
* PluginDir/Resource/config/services.yamlでeccube_update_plugin_410_411_php_pathを定義した場合、こちらが優先されます。
* PluginDir/Resource/config/services.yamlでeccube_update_plugin_411_412_php_pathを定義した場合、こちらが優先されます。
*
* @return false|string
*/
private function getPhpPath()
{
$phpPath = $this->eccubeConfig->get('eccube_update_plugin_410_411_php_path');
$phpPath = $this->eccubeConfig->get('eccube_update_plugin_411_412_php_path');
if ($phpPath && @is_executable($phpPath)) {
return $phpPath;
}
Expand Down
2 changes: 1 addition & 1 deletion Resource/config/services.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
parameters:
eccube_update_plugin_410_411_php_path: ~
eccube_update_plugin_411_412_php_path: ~
6 changes: 2 additions & 4 deletions Resource/file_hash/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
},
"minimum-stability": "stable",
"require": {
"php": "^7.1.3",
"php": "^7.3",
"ext-intl": "*",
"ext-mbstring": "*",
"composer/ca-bundle": "^1.1",
Expand Down Expand Up @@ -72,7 +72,6 @@
"symfony/css-selector": "^4.4",
"symfony/debug": "^4.4",
"symfony/debug-bundle": "^4.4",
"symfony/debug-pack": "^1.0",
"symfony/dependency-injection": "^4.4",
"symfony/doctrine-bridge": "^4.4",
"symfony/dom-crawler": "^4.4",
Expand All @@ -92,7 +91,6 @@
"symfony/monolog-bridge": "^4.4",
"symfony/monolog-bundle": "^3.1",
"symfony/options-resolver": "^4.4",
"symfony/orm-pack": "^1.0",
"symfony/process": "^4.4",
"symfony/property-access": "^4.4",
"symfony/proxy-manager-bridge": "^4.4",
Expand Down Expand Up @@ -200,7 +198,7 @@
},
"config": {
"platform": {
"php": "7.3.30"
"php": "7.3.0"
},
"preferred-install": {
"*": "dist"
Expand Down
Loading

0 comments on commit 4b686cc

Please sign in to comment.