diff --git a/.travis.yml b/.travis.yml index c81ab7f..c4aac71 100644 --- a/.travis.yml +++ b/.travis.yml @@ -18,12 +18,15 @@ cache: - $HOME/.composer/cache before_script: + - composer self-update --1 # Enforce composer v1.x is used - phpenv config-rm xdebug.ini || true - travis_retry composer install --no-interaction --prefer-dist script: - bin/phpunit - - if [[ "$RELEASE" == "true" ]]; then composer run compile; fi + - bin/raml-code-generator + - composer run compile + - dist/raml-code-generator.phar deploy: provider: releases diff --git a/CHANGELOG.md b/CHANGELOG.md index d6284ed..9177b59 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,17 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## 11.2.3 +### Fixed +- The compiled `raml-code-generator.phar` command now does not report any errors. + +## 11.2.2 +### Changed +- Use another encrypted Travis CI token, as encryption is related to the repository. + +## 11.2.1 +N/A (empty version) + ## 11.2.0 ### Changed - Requires at least PHP 7.2, updates used internal libraries. diff --git a/bin/raml-code-generator b/bin/raml-code-generator index b31cef2..e8fb2bd 100755 --- a/bin/raml-code-generator +++ b/bin/raml-code-generator @@ -4,7 +4,6 @@ declare(strict_types=1, ticks=1); use Paysera\Component\Console\Application; -use Paysera\Component\Console\PharKernel; use Symfony\Component\Console\Input\ArgvInput; use Symfony\Component\Console\Output\ConsoleOutput; @@ -12,6 +11,6 @@ set_time_limit(0); require __DIR__ . '/../vendor/autoload.php'; -$kernel = new PharKernel('phar', false); +$kernel = new AppKernel('phar', false); $application = new Application($kernel); $application->run(new ArgvInput(), new ConsoleOutput()); diff --git a/box.json b/box.json index 5f74bb4..23e9d6d 100644 --- a/box.json +++ b/box.json @@ -8,7 +8,7 @@ { "name": ["*.php", "*.xml", "*.yml", "*.xsd", "*.db", "*.twig"], "exclude": ["test", "Tests", "tests"], - "in": ["src", "vendor", "app"] + "in": ["src", "vendor", "app", "var/cache"] } ], "blacklist": [ diff --git a/composer.json b/composer.json index a0cce9d..6ce474f 100644 --- a/composer.json +++ b/composer.json @@ -58,7 +58,10 @@ "symfony/phpunit-bridge": "^3.0" }, "scripts": { - "compile": "box compile", + "compile": [ + "bin/console cache:warmup --no-debug --env phar", + "box compile" + ], "symfony-scripts": [ "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters", "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache" diff --git a/src/Paysera/Component/Console/PharKernel.php b/src/Paysera/Component/Console/PharKernel.php deleted file mode 100644 index c2f0308..0000000 --- a/src/Paysera/Component/Console/PharKernel.php +++ /dev/null @@ -1,31 +0,0 @@ -buildContainer(); - $container->compile(); - - $this->container = $container; - $this->container->set('kernel', $this); - } - - protected function buildContainer() - { - $container = $this->getContainerBuilder(); - $container->addObjectResource($this); - $this->prepareContainer($container); - - $containerConfiguration = $this->registerContainerConfiguration($this->getContainerLoader($container)); - if ($containerConfiguration !== null) { - $container->merge($containerConfiguration); - } - - return $container; - } -}