From 09b5f10506b3940270ae374f7f4d0ae5fadabfd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20K=C3=A4hm?= Date: Tue, 17 Dec 2024 19:51:48 +0100 Subject: [PATCH] [TASK] Extract sclable/xml-lint to global Makes it possible to run CI on PHP 8.4+ --- .github/workflows/ci.yml | 2 +- composer.json | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7bfffd88..353c6473 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -103,7 +103,7 @@ jobs: SSH_AUTH_SOCK: /tmp/ssh_agent.sock run: | composer info - composer tests:setup + composer tests:setup && composer tests:setup:global-require echo "Current Size of EXT:tika build Artefacts: " \ && sudo du -sh "${{ env.CI_BUILD_DIRECTORY }}" - diff --git a/composer.json b/composer.json index b17693dd..0cc05b63 100644 --- a/composer.json +++ b/composer.json @@ -38,7 +38,6 @@ "phpstan/phpstan": "^1.12", "phpstan/phpstan-phpunit": "^1.4", "phpunit/phpunit": "^11.4", - "sclable/xml-lint": "^0.8.0", "typo3/cms-lowlevel": "*", "typo3/coding-standards": "v0.8.0", "typo3/testing-framework": "^9.0.1" @@ -123,6 +122,10 @@ "if [ -z ${TIKA_PATH+x} ]; then echo \"Can not proceed, because env var TIKA_PATH is not set\"; exit 1; fi", "if echo $TYPO3_VERSION | grep -q \"dev\"; then $COMPOSER_BINARY config minimum-stability dev; fi" ], + "tests:setup:global-require": [ + "echo \"Install global composer dependencies.\"", + "@composer global require sclable/xml-lint --ignore-platform-reqs" + ], "tests:setup": [ "# @todo: Abort if composer.json has not staged/commited changes on composer.json, to avoid losing necessery changes.", "@tests:env", @@ -147,7 +150,7 @@ ], "tests:lint-xml": [ "echo \"Run XML Lint\"", - "if ! xmllint Resources/Private/Language/ --pattern='*.xlf' --exclude=.Build/*; then echo \"Some XML files are not valid\" && echo \"Please fix the files listed above\" && export EXIT_CODE=4; else echo \"No syntax errors! Great job!\"; fi" + "if ! $($COMPOSER_BINARY config home)/vendor/bin/xmllint Resources/Private/Language/ --pattern='*.xlf' --exclude=.Build/*; then echo \"Some XML files are not valid\" && echo \"Please fix the files listed above\" && export EXIT_CODE=4; else echo \"No syntax errors! Great job!\"; fi" ] }, "extra": {