Skip to content

Commit

Permalink
Updated GitHub workflow files
Browse files Browse the repository at this point in the history
- Updated cache & checkout actions
- Added php 8.2 checks
- Added expansion placeholder for php extensions (template)
  • Loading branch information
shudd3r committed Jun 14, 2023
1 parent 0136bb0 commit 02244dd
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
php-versions: ['7.4']
env:
extensions: pcov, dom, json, libxml, mbstring, pdo_sqlite, soap, xml, xmlwriter
key: cache-v2
key: cache-v3
steps:
- name: "Checkout"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: "Setup PHP extensions cache environment"
id: cache-env
uses: shivammathur/cache-extensions@v1
Expand All @@ -23,7 +23,7 @@ jobs:
extensions: ${{ env.extensions }}
key: ${{ env.key }}
- name: "Cache PHP extensions"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ${{ steps.cache-env.outputs.dir }}
key: ${{ steps.cache-env.outputs.key }}
Expand All @@ -38,7 +38,7 @@ jobs:
- name: "Validate composer.json"
run: composer validate
- name: "Setup composer cache"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
Expand Down Expand Up @@ -69,15 +69,15 @@ jobs:
strategy:
matrix:
operating-system: ['ubuntu-latest', 'windows-latest', 'macos-latest']
php-versions: ['8.0', '8.1']
php-versions: ['8.0', '8.1', '8.2']
env:
extensions: dom, json, libxml, mbstring, pdo_sqlite, soap, xml, xmlwriter
key: cache-v2
key: cache-v3
steps:
- name: "Turn off git EOL conversion"
run: git config --global core.autocrlf false
- name: "Checkout"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: "Setup PHP extensions cache environment"
id: cache-env
uses: shivammathur/cache-extensions@v1
Expand All @@ -86,7 +86,7 @@ jobs:
extensions: ${{ env.extensions }}
key: ${{ env.key }}
- name: "Cache PHP extensions"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ${{ steps.cache-env.outputs.dir }}
key: ${{ steps.cache-env.outputs.key }}
Expand All @@ -99,7 +99,7 @@ jobs:
extensions: ${{ env.extensions }}
ini-values: assert.exception=1, zend.assertions=1
- name: "Setup composer cache"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: ${{ runner.os }}-php${{ matrix.php-versions }}-composer-${{ hashFiles('**/composer.json') }}
Expand Down
22 changes: 11 additions & 11 deletions template/.github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ jobs:
operating-system: ['ubuntu-latest']
php-versions: ['7.4']
env:
extensions: pcov, dom, json, libxml, mbstring, pdo_sqlite, soap, xml, xmlwriter
key: cache-v2
extensions: pcov, dom, json, libxml, mbstring, pdo_sqlite, soap, xml, xmlwriter{original.content}
key: cache-v3
steps:
- name: "Checkout"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: "Setup PHP extensions cache environment"
id: cache-env
uses: shivammathur/cache-extensions@v1
Expand All @@ -23,7 +23,7 @@ jobs:
extensions: ${{ env.extensions }}
key: ${{ env.key }}
- name: "Cache PHP extensions"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ${{ steps.cache-env.outputs.dir }}
key: ${{ steps.cache-env.outputs.key }}
Expand All @@ -38,7 +38,7 @@ jobs:
- name: "Validate composer.json"
run: composer validate
- name: "Setup composer cache"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
Expand Down Expand Up @@ -69,15 +69,15 @@ jobs:
strategy:
matrix:
operating-system: ['ubuntu-latest', 'windows-latest', 'macos-latest']
php-versions: ['8.0', '8.1']
php-versions: ['8.0', '8.1', '8.2']
env:
extensions: dom, json, libxml, mbstring, pdo_sqlite, soap, xml, xmlwriter
key: cache-v2
extensions: dom, json, libxml, mbstring, pdo_sqlite, soap, xml, xmlwriter{original.content}
key: cache-v3
steps:
- name: "Turn off git EOL conversion"
run: git config --global core.autocrlf false
- name: "Checkout"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: "Setup PHP extensions cache environment"
id: cache-env
uses: shivammathur/cache-extensions@v1
Expand All @@ -86,7 +86,7 @@ jobs:
extensions: ${{ env.extensions }}
key: ${{ env.key }}
- name: "Cache PHP extensions"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ${{ steps.cache-env.outputs.dir }}
key: ${{ steps.cache-env.outputs.key }}
Expand All @@ -99,7 +99,7 @@ jobs:
extensions: ${{ env.extensions }}
ini-values: assert.exception=1, zend.assertions=1
- name: "Setup composer cache"
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: ${{ runner.os }}-php${{ matrix.php-versions }}-composer-${{ hashFiles('**/composer.json') }}
Expand Down

0 comments on commit 02244dd

Please sign in to comment.