From 8038a475f3207541a1def15b423334f20580e173 Mon Sep 17 00:00:00 2001 From: Anatoliy Melnikov <5785276@gmail.com> Date: Sun, 27 Oct 2024 11:14:37 +0300 Subject: [PATCH] Change model of installation of components by Phive --- .github/workflows/automated_testing.yml | 66 +++++-------------------- 1 file changed, 11 insertions(+), 55 deletions(-) diff --git a/.github/workflows/automated_testing.yml b/.github/workflows/automated_testing.yml index 21b73c4..bbeda04 100644 --- a/.github/workflows/automated_testing.yml +++ b/.github/workflows/automated_testing.yml @@ -29,6 +29,7 @@ jobs: - uses: shivammathur/setup-php@v2 with: php-version: 8.2 + tools: composer,phive - uses: actions/checkout@v4 @@ -50,18 +51,8 @@ jobs: key: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-${{ hashFiles('**/.phive/phars.xml', '**/.phive/trust-gpg-keys.txt') }}" restore-keys: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-" - - name: Install PHIVE - uses: szepeviktor/phive@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - - name: Install PHP tools by PHIVE - uses: szepeviktor/phive-install@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - trustGpgKeys: '$(cat ./.phive/trust-gpg-keys.txt)' + run: composer phive-install - name: Check composer requirements run: composer require-check @@ -74,6 +65,7 @@ jobs: - uses: shivammathur/setup-php@v2 with: php-version: 8.2 + tools: composer,phive - uses: actions/checkout@v4 @@ -95,18 +87,8 @@ jobs: key: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-${{ hashFiles('**/.phive/phars.xml', '**/.phive/trust-gpg-keys.txt') }}" restore-keys: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-" - - name: Install PHIVE - uses: szepeviktor/phive@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - - name: Install PHP tools by PHIVE - uses: szepeviktor/phive-install@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - trustGpgKeys: '$(cat ./.phive/trust-gpg-keys.txt)' + run: composer phive-install - name: Check unused composer requirements run: composer unused @@ -119,6 +101,7 @@ jobs: - uses: shivammathur/setup-php@v2 with: php-version: 8.2 + tools: composer,phive - uses: actions/checkout@v4 @@ -140,18 +123,8 @@ jobs: key: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-${{ hashFiles('**/.phive/phars.xml', '**/.phive/trust-gpg-keys.txt') }}" restore-keys: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-" - - name: Install PHIVE - uses: szepeviktor/phive@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - - name: Install PHP tools by PHIVE - uses: szepeviktor/phive-install@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - trustGpgKeys: '$(cat ./.phive/trust-gpg-keys.txt)' + run: composer phive-install - name: 'Run PHP CS Fixer: check' run: composer run cs-fixer-check @@ -164,6 +137,7 @@ jobs: - uses: shivammathur/setup-php@v2 with: php-version: 8.2 + tools: composer,phive - uses: actions/checkout@v4 @@ -185,18 +159,8 @@ jobs: key: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-${{ hashFiles('**/.phive/phars.xml', '**/.phive/trust-gpg-keys.txt') }}" restore-keys: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-" - - name: Install PHIVE - uses: szepeviktor/phive@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - - name: Install PHP tools by PHIVE - uses: szepeviktor/phive-install@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - trustGpgKeys: '$(cat ./.phive/trust-gpg-keys.txt)' + run: composer phive-install - name: 'Run PHPStan analyse' run: composer run phpstan-analyse @@ -209,6 +173,7 @@ jobs: - uses: shivammathur/setup-php@v2 with: php-version: 8.2 + tools: composer,phive - uses: actions/checkout@v4 @@ -230,18 +195,8 @@ jobs: key: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-${{ hashFiles('**/.phive/phars.xml', '**/.phive/trust-gpg-keys.txt') }}" restore-keys: "os-${{ runner.os }}-php-${{ runner.php-version }}-phive-" - - name: Install PHIVE - uses: szepeviktor/phive@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - - name: Install PHP tools by PHIVE - uses: szepeviktor/phive-install@v1 - with: - home: "${{ runner.temp }}/.phive" - binPath: "${{ github.workspace }}/tools/phive" - trustGpgKeys: '$(cat ./.phive/trust-gpg-keys.txt)' + run: composer phive-install - name: 'Run all PHPUnit tests' run: composer run phpunit @@ -254,6 +209,7 @@ jobs: - uses: shivammathur/setup-php@v2 with: php-version: 8.2 + tools: composer - uses: actions/checkout@v4