Skip to content

Commit

Permalink
Move Symfony FileSystem into library for compat w WP Engine
Browse files Browse the repository at this point in the history
  • Loading branch information
cjhaas committed Jun 20, 2023
1 parent b7b12ab commit 9a8035a
Show file tree
Hide file tree
Showing 8 changed files with 883 additions and 4 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
[![PHP Composer](https://github.com/vendi-advertising/vendi-yaml-loader/actions/workflows/php.yml/badge.svg)](https://github.com/vendi-advertising/vendi-yaml-loader/actions/workflows/php.yml)

## Notes

* In order to support WP Engine which is still capped at PHP 8.0, the Symfony FileSystem Path class
was brought into this library. This is a temporary measure until WP Engine supports at least PHP 8.1.
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@
},
"require": {
"php": "^8.0|^8.1|^8.2",
"symfony/yaml": "^5.0.8|^6",
"symfony/filesystem": "^6.2"
"symfony/yaml": "^5.0.8|^6"
},
"require-dev": {
"roave/security-advisories": "dev-latest",
Expand Down
21 changes: 21 additions & 0 deletions src/SymfonyFileSystem/ExceptionInterface.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?php

/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

namespace Vendi\YamlLoader\SymfonyFileSystem;

/**
* Exception interface for all exceptions thrown by the component.
*
* @author Romain Neutron <imprec@gmail.com>
*/
interface ExceptionInterface extends \Throwable
{
}
19 changes: 19 additions & 0 deletions src/SymfonyFileSystem/InvalidArgumentException.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?php

/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

namespace Vendi\YamlLoader\SymfonyFileSystem;

/**
* @author Christian Flothmann <christian.flothmann@sensiolabs.de>
*/
class InvalidArgumentException extends \InvalidArgumentException implements ExceptionInterface
{
}

0 comments on commit 9a8035a

Please sign in to comment.