From 41a7011e682fcf7551138cd685f9c80b61ab02df Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:20:59 +0100 Subject: [PATCH 1/7] update php requires semantic --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index d610d411..db93e9d3 100644 --- a/composer.json +++ b/composer.json @@ -18,7 +18,7 @@ } ], "require": { - "php": "~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0", + "php": ">=8.0", "jms/serializer": "^3.18", "ext-dom": "*" }, From 5df1bbd2b4017283f1dab0bd09d3fe73626f1f78 Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:21:33 +0100 Subject: [PATCH 2/7] update dependabot alerts --- .github/dependabot.yml | 38 +++++++++++++------------------------- 1 file changed, 13 insertions(+), 25 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 4ae74ece..fc88e125 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,25 +1,13 @@ -{ - "version": 2, - "updates": [ - { - "allow": [ - { - "dependency-type": "all" - } - ], - "directory": "/", - "package-ecosystem": "composer", - "schedule": { - "interval": "daily" - }, - "versioning-strategy": "increase" - }, - { - "directory": "/", - "package-ecosystem": "github-actions", - "schedule": { - "interval": "daily" - } - } - ] -} +version: 2 +updates: + - allow: + - dependency-type: "all" + directory: "/" + package-ecosystem: "composer" + schedule: + interval: "weekly" + versioning-strategy: "increase" + - directory: "/" + package-ecosystem: "github-actions" + schedule: + interval: "weekly" From 51e880c12bcb9a030fd8f031bf5f29725c0c9199 Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:22:11 +0100 Subject: [PATCH 3/7] lint readme --- .laminas-ci.json | 7 ------- README.md | 3 +-- 2 files changed, 1 insertion(+), 9 deletions(-) delete mode 100644 .laminas-ci.json diff --git a/.laminas-ci.json b/.laminas-ci.json deleted file mode 100644 index a62e148d..00000000 --- a/.laminas-ci.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "exclude": [ - { - "name": "README Linting [8.0, latest]" - } - ] -} diff --git a/README.md b/README.md index 8b1adc54..d27f8958 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ -ZUGFeRD PHP -=========== +# ZUGFeRD PHP [![Latest Stable Version](https://poser.pugx.org/silarhi/zugferd-factur-x/v/stable.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) [![Total Downloads](https://poser.pugx.org/silarhi/zugferd-factur-x/downloads.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) [![Latest Unstable Version](https://poser.pugx.org/silarhi/zugferd-factur-x/v/unstable.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) [![License](https://poser.pugx.org/silarhi/zugferd-factur-x/license.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) From 7c0a983ce86242a4abd7ce4fa562bd88ed5ee7e4 Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:22:39 +0100 Subject: [PATCH 4/7] use laminas ci actions to run phpstan --- .github/workflows/phpstan.yml | 52 ----------------------------------- .laminas-ci.json | 11 ++++++++ 2 files changed, 11 insertions(+), 52 deletions(-) delete mode 100644 .github/workflows/phpstan.yml create mode 100644 .laminas-ci.json diff --git a/.github/workflows/phpstan.yml b/.github/workflows/phpstan.yml deleted file mode 100644 index 3c5fda8f..00000000 --- a/.github/workflows/phpstan.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: PHPStan -on: - pull_request: - push: - branches: - - 'refs/pull/*' - - '5.x' - -env: - CI: true - -jobs: - run: - name: PHPStan ${{ matrix.php }} on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - - strategy: - fail-fast: false - matrix: - os: [ ubuntu-latest ] - php: [ '8.2' ] - - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Install PHP - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php }} - ini-values: memory_limit=-1 - tools: composer:v2 - - - name: Determine composer cache directory - id: composer-cache - run: | - echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - - - name: Cache composer dependencies - uses: actions/cache@v4.0.0 - with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ matrix.php }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: | - ${{ matrix.php }}-composer- - - - name: Install Dependencies - run: composer update --no-progress --ansi - - - name: PHPStan - run: ./vendor/bin/phpstan analyse diff --git a/.laminas-ci.json b/.laminas-ci.json new file mode 100644 index 00000000..46a9f393 --- /dev/null +++ b/.laminas-ci.json @@ -0,0 +1,11 @@ +{ + "additional_checks": [ + { + "name": "PHPStan", + "job": { + "command": "./vendor/bin/phpstan analyse", + "php": "8.2" + } + } + ] +} From efd2b0fc6506e914912829031d4a9fad6ebe957a Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:22:44 +0100 Subject: [PATCH 5/7] remove redundant job --- .github/workflows/cs.yaml | 37 ------------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 .github/workflows/cs.yaml diff --git a/.github/workflows/cs.yaml b/.github/workflows/cs.yaml deleted file mode 100644 index c2496e6c..00000000 --- a/.github/workflows/cs.yaml +++ /dev/null @@ -1,37 +0,0 @@ -name: Code Style - -on: - pull_request: - push: - branches: - - 'refs/pull/*' - - 'main' - -jobs: - build: - runs-on: ubuntu-latest - - strategy: - matrix: - include: - - { operating-system: 'ubuntu-latest', php-version: '8.2', dependencies: '' } - - name: PHP ${{ matrix.php-version }} - - steps: - - uses: actions/checkout@v2 - - - name: Setup PHP - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php-version }} - coverage: pcov - tools: composer:v2 - - - name: Install dependencies - run: | - composer install --no-interaction --prefer-dist --no-progress ${{ matrix.dependencies }} - - - name: Check code style - run: | - php vendor/bin/php-cs-fixer --using-cache=no --diff --dry-run --stop-on-violation --verbose fix From 175113ea65ffa5fd8661670b07d71513efd80646 Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:23:06 +0100 Subject: [PATCH 6/7] prettify yaml files --- .github/workflows/continuous-integration.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 1981e254..25567412 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -4,8 +4,8 @@ on: pull_request: push: branches: - - 'refs/pull/*' - - 'main' + - "refs/pull/*" + - "main" jobs: matrix: From 28f19b9f27240b95445a4e9211e477380790b6ef Mon Sep 17 00:00:00 2001 From: Guillaume Sainthillier Date: Fri, 9 Feb 2024 12:25:31 +0100 Subject: [PATCH 7/7] Update README badges --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index d27f8958..85b19817 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,9 @@ # ZUGFeRD PHP -[![Latest Stable Version](https://poser.pugx.org/silarhi/zugferd-factur-x/v/stable.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) [![Total Downloads](https://poser.pugx.org/silarhi/zugferd-factur-x/downloads.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) [![Latest Unstable Version](https://poser.pugx.org/silarhi/zugferd-factur-x/v/unstable.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) [![License](https://poser.pugx.org/silarhi/zugferd-factur-x/license.png)](https://packagist.org/packages/silarhi/zugferd-factur-x) +![Build Status](https://github.com/silarhi/zugferd-factur-x/actions/workflows/continuous-integration.yml/badge.svg) +[![Latest Stable Version](https://poser.pugx.org/silarhi/zugferd-factur-x/v/stable)](https://packagist.org/packages/silarhi/zugferd-factur-x) +[![Total Downloads](https://poser.pugx.org/silarhi/zugferd-factur-x/downloads)](https://packagist.org/packages/silarhi/zugferd-factur-x) +[![License](https://poser.pugx.org/silarhi/zugferd-factur-x/license)](https://packagist.org/packages/silarhi/zugferd-factur-x) XML generator for ZUGFeRD / Factur-X / XRechnung written in PHP. Convert PHP Objects to XML and back.