From d36ca2b71964fd6819016c56081e691391d2cb30 Mon Sep 17 00:00:00 2001 From: JBlond Date: Sat, 19 Jan 2019 20:01:12 +0100 Subject: [PATCH 1/8] change PHP version --- lib/jblond/Diff.php | 2 +- lib/jblond/Diff/Renderer/Html/HtmlArray.php | 2 +- lib/jblond/Diff/Renderer/Html/Inline.php | 2 +- lib/jblond/Diff/Renderer/Html/SideBySide.php | 2 +- lib/jblond/Diff/Renderer/RendererAbstract.php | 2 +- lib/jblond/Diff/Renderer/Text/Context.php | 2 +- lib/jblond/Diff/Renderer/Text/Unified.php | 2 +- lib/jblond/Diff/SequenceMatcher.php | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/jblond/Diff.php b/lib/jblond/Diff.php index e9a8747e..4d44c60c 100644 --- a/lib/jblond/Diff.php +++ b/lib/jblond/Diff.php @@ -10,7 +10,7 @@ * A comprehensive library for generating differences between two strings * in multiple formats (unified, side by side HTML etc) * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/Renderer/Html/HtmlArray.php b/lib/jblond/Diff/Renderer/Html/HtmlArray.php index cce0d95f..8710072f 100644 --- a/lib/jblond/Diff/Renderer/Html/HtmlArray.php +++ b/lib/jblond/Diff/Renderer/Html/HtmlArray.php @@ -7,7 +7,7 @@ /** * Base renderer for rendering HTML based diffs for PHP DiffLib. * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/Renderer/Html/Inline.php b/lib/jblond/Diff/Renderer/Html/Inline.php index a46f25d4..a442db8f 100644 --- a/lib/jblond/Diff/Renderer/Html/Inline.php +++ b/lib/jblond/Diff/Renderer/Html/Inline.php @@ -5,7 +5,7 @@ /** * Inline HTML diff generator for PHP DiffLib. * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/Renderer/Html/SideBySide.php b/lib/jblond/Diff/Renderer/Html/SideBySide.php index 57c9fd09..b3aaa870 100644 --- a/lib/jblond/Diff/Renderer/Html/SideBySide.php +++ b/lib/jblond/Diff/Renderer/Html/SideBySide.php @@ -5,7 +5,7 @@ /** * Side by Side HTML diff generator for PHP DiffLib. * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/Renderer/RendererAbstract.php b/lib/jblond/Diff/Renderer/RendererAbstract.php index 401b3e53..860fa91c 100644 --- a/lib/jblond/Diff/Renderer/RendererAbstract.php +++ b/lib/jblond/Diff/Renderer/RendererAbstract.php @@ -5,7 +5,7 @@ /** * Abstract class for diff renderers in PHP DiffLib. * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/Renderer/Text/Context.php b/lib/jblond/Diff/Renderer/Text/Context.php index 8865c9b6..66f5ab56 100644 --- a/lib/jblond/Diff/Renderer/Text/Context.php +++ b/lib/jblond/Diff/Renderer/Text/Context.php @@ -7,7 +7,7 @@ /** * Context diff generator for PHP DiffLib. * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/Renderer/Text/Unified.php b/lib/jblond/Diff/Renderer/Text/Unified.php index 901a95b6..d4824cb6 100644 --- a/lib/jblond/Diff/Renderer/Text/Unified.php +++ b/lib/jblond/Diff/Renderer/Text/Unified.php @@ -7,7 +7,7 @@ /** * Unified diff generator for PHP DiffLib. * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * diff --git a/lib/jblond/Diff/SequenceMatcher.php b/lib/jblond/Diff/SequenceMatcher.php index 5d3f5a15..c7654979 100644 --- a/lib/jblond/Diff/SequenceMatcher.php +++ b/lib/jblond/Diff/SequenceMatcher.php @@ -5,7 +5,7 @@ /** * Sequence matcher for Diff * - * PHP version 5 + * PHP version 7.1 or greater * * Copyright (c) 2009 Chris Boulton * From 6311fd4b350a0e689cdd690febf2e239dc1d9dde Mon Sep 17 00:00:00 2001 From: JBlond Date: Sat, 19 Jan 2019 20:02:54 +0100 Subject: [PATCH 2/8] refer to License file --- README.md | 31 +------------------------------ 1 file changed, 1 insertion(+), 30 deletions(-) diff --git a/README.md b/README.md index 33e9c038..0f01642a 100644 --- a/README.md +++ b/README.md @@ -54,34 +54,5 @@ Contributors since I forked the repo. License (BSD License) --------------------- -Copyright (c) 2009 Chris Boulton -Copyright (c) 2015 Mario Brandt - -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - - - Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - - Neither the name of the Chris Boulton nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - -``` -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE -LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -POSSIBILITY OF SUCH DAMAGE. -``` +see [License](LICENSE) From 3df01ccd3671228487cdf36ec11b923ab721bbed Mon Sep 17 00:00:00 2001 From: JBlond Date: Sat, 19 Jan 2019 20:04:18 +0100 Subject: [PATCH 3/8] relative path to pictures --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0f01642a..7430cc7f 100644 --- a/README.md +++ b/README.md @@ -24,9 +24,9 @@ Example Use A quick usage example can be found in the example/ directory and under example.php. -![Example Image](https://github.com/jblond/php-diff/raw/master/readme.png "Example") +![Example Image](readme.png "Example") -![Example 2 Image](https://github.com/jblond/php-diff/raw/master/readme2.png "Example2") +![Example 2 Image](readme2.png "Example2") Requirements ----------- From b4cfce1dd8ae54053da4cc97b4a3761f871d7be3 Mon Sep 17 00:00:00 2001 From: JBlond Date: Sat, 19 Jan 2019 21:06:49 +0100 Subject: [PATCH 4/8] fix test --- tests/Diff/Renderer/ArrayTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/Diff/Renderer/ArrayTest.php b/tests/Diff/Renderer/ArrayTest.php index f83392a8..8fcffd6d 100644 --- a/tests/Diff/Renderer/ArrayTest.php +++ b/tests/Diff/Renderer/ArrayTest.php @@ -5,6 +5,8 @@ use jblond\Diff\Renderer\Html\HtmlArray; use PHPUnit\Framework\TestCase; +require "../../../lib/Autoloader.php"; + /** * Class ArrayTest * @package Tests\Diff\Renderer\Html @@ -20,7 +22,6 @@ class ArrayTest extends TestCase */ public function __construct($name = null, array $data = [], $dataName = '') { - require "../../../lib/Autoloader.php"; new \jblond\Autoloader(); parent::__construct($name, $data, $dataName); } From 7d22093ee80e6dab44edb524909e811b8e55e8bc Mon Sep 17 00:00:00 2001 From: JBlond Date: Sat, 19 Jan 2019 21:09:57 +0100 Subject: [PATCH 5/8] increase version number --- lib/jblond/Diff.php | 2 +- lib/jblond/Diff/Renderer/Html/HtmlArray.php | 2 +- lib/jblond/Diff/Renderer/Html/Inline.php | 2 +- lib/jblond/Diff/Renderer/Html/SideBySide.php | 2 +- lib/jblond/Diff/Renderer/RendererAbstract.php | 2 +- lib/jblond/Diff/Renderer/Text/Context.php | 2 +- lib/jblond/Diff/Renderer/Text/Unified.php | 2 +- lib/jblond/Diff/SequenceMatcher.php | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/jblond/Diff.php b/lib/jblond/Diff.php index 4d44c60c..0ebb3d38 100644 --- a/lib/jblond/Diff.php +++ b/lib/jblond/Diff.php @@ -44,7 +44,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ class Diff diff --git a/lib/jblond/Diff/Renderer/Html/HtmlArray.php b/lib/jblond/Diff/Renderer/Html/HtmlArray.php index 8710072f..fc75ca12 100644 --- a/lib/jblond/Diff/Renderer/Html/HtmlArray.php +++ b/lib/jblond/Diff/Renderer/Html/HtmlArray.php @@ -41,7 +41,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/Html/Inline.php b/lib/jblond/Diff/Renderer/Html/Inline.php index a442db8f..1efe627e 100644 --- a/lib/jblond/Diff/Renderer/Html/Inline.php +++ b/lib/jblond/Diff/Renderer/Html/Inline.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/Html/SideBySide.php b/lib/jblond/Diff/Renderer/Html/SideBySide.php index b3aaa870..85a9765f 100644 --- a/lib/jblond/Diff/Renderer/Html/SideBySide.php +++ b/lib/jblond/Diff/Renderer/Html/SideBySide.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/RendererAbstract.php b/lib/jblond/Diff/Renderer/RendererAbstract.php index 860fa91c..cb05f2ba 100644 --- a/lib/jblond/Diff/Renderer/RendererAbstract.php +++ b/lib/jblond/Diff/Renderer/RendererAbstract.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ abstract class RendererAbstract diff --git a/lib/jblond/Diff/Renderer/Text/Context.php b/lib/jblond/Diff/Renderer/Text/Context.php index 66f5ab56..81c4462a 100644 --- a/lib/jblond/Diff/Renderer/Text/Context.php +++ b/lib/jblond/Diff/Renderer/Text/Context.php @@ -41,7 +41,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/Text/Unified.php b/lib/jblond/Diff/Renderer/Text/Unified.php index d4824cb6..f43eec81 100644 --- a/lib/jblond/Diff/Renderer/Text/Unified.php +++ b/lib/jblond/Diff/Renderer/Text/Unified.php @@ -41,7 +41,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/SequenceMatcher.php b/lib/jblond/Diff/SequenceMatcher.php index c7654979..67352055 100644 --- a/lib/jblond/Diff/SequenceMatcher.php +++ b/lib/jblond/Diff/SequenceMatcher.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.6 + * @version 1.7 * @link https://github.com/JBlond/php-diff */ class SequenceMatcher From 7699e4ff0239b8faa80ad9c2409cc4f5bff182a8 Mon Sep 17 00:00:00 2001 From: JBlond Date: Wed, 13 Feb 2019 17:39:37 +0100 Subject: [PATCH 6/8] PSR1.Files.SideEffects.FoundWithSymbols --- tests/Diff/Renderer/ArrayTest.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/Diff/Renderer/ArrayTest.php b/tests/Diff/Renderer/ArrayTest.php index 8fcffd6d..f83392a8 100644 --- a/tests/Diff/Renderer/ArrayTest.php +++ b/tests/Diff/Renderer/ArrayTest.php @@ -5,8 +5,6 @@ use jblond\Diff\Renderer\Html\HtmlArray; use PHPUnit\Framework\TestCase; -require "../../../lib/Autoloader.php"; - /** * Class ArrayTest * @package Tests\Diff\Renderer\Html @@ -22,6 +20,7 @@ class ArrayTest extends TestCase */ public function __construct($name = null, array $data = [], $dataName = '') { + require "../../../lib/Autoloader.php"; new \jblond\Autoloader(); parent::__construct($name, $data, $dataName); } From 5d22b819e4ead530837b96b9e9b509bb215083b1 Mon Sep 17 00:00:00 2001 From: JBlond Date: Wed, 13 Feb 2019 17:42:42 +0100 Subject: [PATCH 7/8] update version string --- lib/jblond/Diff.php | 2 +- lib/jblond/Diff/Renderer/Html/HtmlArray.php | 2 +- lib/jblond/Diff/Renderer/Html/Inline.php | 2 +- lib/jblond/Diff/Renderer/Html/SideBySide.php | 2 +- lib/jblond/Diff/Renderer/RendererAbstract.php | 2 +- lib/jblond/Diff/Renderer/Text/Context.php | 2 +- lib/jblond/Diff/Renderer/Text/Unified.php | 2 +- lib/jblond/Diff/SequenceMatcher.php | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/jblond/Diff.php b/lib/jblond/Diff.php index 0ebb3d38..f90b924a 100644 --- a/lib/jblond/Diff.php +++ b/lib/jblond/Diff.php @@ -44,7 +44,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ class Diff diff --git a/lib/jblond/Diff/Renderer/Html/HtmlArray.php b/lib/jblond/Diff/Renderer/Html/HtmlArray.php index fc75ca12..4d1f205f 100644 --- a/lib/jblond/Diff/Renderer/Html/HtmlArray.php +++ b/lib/jblond/Diff/Renderer/Html/HtmlArray.php @@ -41,7 +41,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/Html/Inline.php b/lib/jblond/Diff/Renderer/Html/Inline.php index 1efe627e..36f97425 100644 --- a/lib/jblond/Diff/Renderer/Html/Inline.php +++ b/lib/jblond/Diff/Renderer/Html/Inline.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/Html/SideBySide.php b/lib/jblond/Diff/Renderer/Html/SideBySide.php index 85a9765f..510acedd 100644 --- a/lib/jblond/Diff/Renderer/Html/SideBySide.php +++ b/lib/jblond/Diff/Renderer/Html/SideBySide.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/RendererAbstract.php b/lib/jblond/Diff/Renderer/RendererAbstract.php index cb05f2ba..b3c29bf5 100644 --- a/lib/jblond/Diff/Renderer/RendererAbstract.php +++ b/lib/jblond/Diff/Renderer/RendererAbstract.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ abstract class RendererAbstract diff --git a/lib/jblond/Diff/Renderer/Text/Context.php b/lib/jblond/Diff/Renderer/Text/Context.php index 81c4462a..5bf7c985 100644 --- a/lib/jblond/Diff/Renderer/Text/Context.php +++ b/lib/jblond/Diff/Renderer/Text/Context.php @@ -41,7 +41,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/Renderer/Text/Unified.php b/lib/jblond/Diff/Renderer/Text/Unified.php index f43eec81..4f328031 100644 --- a/lib/jblond/Diff/Renderer/Text/Unified.php +++ b/lib/jblond/Diff/Renderer/Text/Unified.php @@ -41,7 +41,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ diff --git a/lib/jblond/Diff/SequenceMatcher.php b/lib/jblond/Diff/SequenceMatcher.php index bf810b0a..ccd9c49e 100644 --- a/lib/jblond/Diff/SequenceMatcher.php +++ b/lib/jblond/Diff/SequenceMatcher.php @@ -39,7 +39,7 @@ * @author Chris Boulton * @copyright (c) 2009 Chris Boulton * @license New BSD License http://www.opensource.org/licenses/bsd-license.php - * @version 1.7 + * @version 1.8 * @link https://github.com/JBlond/php-diff */ class SequenceMatcher From 523188397a25b87a095292ba0722846ded042f81 Mon Sep 17 00:00:00 2001 From: JBlond Date: Wed, 13 Feb 2019 17:52:09 +0100 Subject: [PATCH 8/8] Revert "PSR1.Files.SideEffects.FoundWithSymbols" make unit test work again This reverts commit 7699e4ff0239b8faa80ad9c2409cc4f5bff182a8. --- tests/Diff/Renderer/ArrayTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/Diff/Renderer/ArrayTest.php b/tests/Diff/Renderer/ArrayTest.php index f83392a8..8fcffd6d 100644 --- a/tests/Diff/Renderer/ArrayTest.php +++ b/tests/Diff/Renderer/ArrayTest.php @@ -5,6 +5,8 @@ use jblond\Diff\Renderer\Html\HtmlArray; use PHPUnit\Framework\TestCase; +require "../../../lib/Autoloader.php"; + /** * Class ArrayTest * @package Tests\Diff\Renderer\Html @@ -20,7 +22,6 @@ class ArrayTest extends TestCase */ public function __construct($name = null, array $data = [], $dataName = '') { - require "../../../lib/Autoloader.php"; new \jblond\Autoloader(); parent::__construct($name, $data, $dataName); }