mirror of
https://github.com/graycoreio/github-actions-magento2.git
synced 2026-06-13 13:14:53 +00:00
Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 462e60345e | |||
| f45372b796 | |||
| 7b5ccf7d9d | |||
| dc2f775d75 | |||
| 5f3ba73bc6 | |||
| 86b01b17fa | |||
| c2c3755729 | |||
| 5d47cda771 | |||
| dc750a9f2f | |||
| 7c0bc65842 | |||
| 89912779a9 |
@@ -0,0 +1,49 @@
|
|||||||
|
# $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
|
||||||
|
# $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
|
||||||
|
# $$ Code Owners $$
|
||||||
|
# $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
|
||||||
|
# $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
|
||||||
|
#
|
||||||
|
# The configuration for Code Owners for graycoreio/magento2-devcontainer.
|
||||||
|
#
|
||||||
|
# For more info see: https://help.github.com/articles/about-codeowners/
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
|
# ================================================
|
||||||
|
# Concepts
|
||||||
|
# ================================================
|
||||||
|
#
|
||||||
|
# A CodeOwner should only review what they are comfortable reviewing. If you're not comfortable, say something.
|
||||||
|
# It is a CodeOwners responsibility to only accept the changes that they understand and deem necessary.
|
||||||
|
# The CodeOwners have final say on whether or not code is accepted.
|
||||||
|
# If multiple CodeOwners are listed, ALL code owners must approve the PR prior to merge.
|
||||||
|
# CodeOwners work in conjunction with Github's "Number of Required Approvals (1)" requirement.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# ================================================
|
||||||
|
# GitHub username registry
|
||||||
|
# ================================================
|
||||||
|
|
||||||
|
# damienwebdev - Damien Retzinger
|
||||||
|
|
||||||
|
|
||||||
|
######################################################################################################
|
||||||
|
#
|
||||||
|
# CODEOWNERS rules
|
||||||
|
# -----------------
|
||||||
|
#
|
||||||
|
# All the following rules are applied in the order specified in this file.
|
||||||
|
# The last rule that matches wins!
|
||||||
|
#
|
||||||
|
# See https://git-scm.com/docs/gitignore#_pattern_format for pattern syntax docs.
|
||||||
|
#
|
||||||
|
######################################################################################################
|
||||||
|
|
||||||
|
|
||||||
|
# ================================================
|
||||||
|
# Default Owners
|
||||||
|
# ================================================
|
||||||
|
|
||||||
|
* @damienwebdev
|
||||||
@@ -36,7 +36,7 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: ./supported-version
|
- uses: ./supported-version
|
||||||
with:
|
with:
|
||||||
kind: currently-supported
|
kind: currently-supported
|
||||||
@@ -50,7 +50,7 @@ jobs:
|
|||||||
fail-fast: false
|
fail-fast: false
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: './coding-standard'
|
- uses: './coding-standard'
|
||||||
with:
|
with:
|
||||||
version: ${{ github.event.inputs.version || '*' }}
|
version: ${{ github.event.inputs.version || '*' }}
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ jobs:
|
|||||||
get-composer-version:
|
get-composer-version:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- name: Set PHP Version
|
- name: Set PHP Version
|
||||||
uses: shivammathur/setup-php@v2
|
uses: shivammathur/setup-php@v2
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ jobs:
|
|||||||
get-magento-version:
|
get-magento-version:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- name: Set PHP Version
|
- name: Set PHP Version
|
||||||
uses: shivammathur/setup-php@v2
|
uses: shivammathur/setup-php@v2
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: ./supported-version
|
- uses: ./supported-version
|
||||||
with:
|
with:
|
||||||
kind: currently-supported
|
kind: currently-supported
|
||||||
@@ -44,7 +44,7 @@ jobs:
|
|||||||
fail-fast: false
|
fail-fast: false
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: ./installation-test
|
- uses: ./installation-test
|
||||||
with:
|
with:
|
||||||
composer_version: ${{ matrix.composer }}
|
composer_version: ${{ matrix.composer }}
|
||||||
|
|||||||
@@ -27,11 +27,12 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: ./supported-version
|
- uses: ./supported-version
|
||||||
with:
|
with:
|
||||||
kind: currently-supported
|
kind: currently-supported
|
||||||
include_services: true
|
include_services: true
|
||||||
|
id: supported-version
|
||||||
integration-workflow:
|
integration-workflow:
|
||||||
needs: compute_matrix
|
needs: compute_matrix
|
||||||
uses: ./.github/workflows/integration.yaml
|
uses: ./.github/workflows/integration.yaml
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ jobs:
|
|||||||
semver-compare:
|
semver-compare:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
|
|
||||||
- uses: ./semver-compare
|
- uses: ./semver-compare
|
||||||
id: version-compare-1
|
id: version-compare-1
|
||||||
|
|||||||
@@ -116,7 +116,7 @@ jobs:
|
|||||||
setup-magento-extension:
|
setup-magento-extension:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
|
|
||||||
- uses: ./setup-magento
|
- uses: ./setup-magento
|
||||||
id: setup-magento
|
id: setup-magento
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: ./supported-version
|
- uses: ./supported-version
|
||||||
with:
|
with:
|
||||||
kind: currently-supported
|
kind: currently-supported
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ jobs:
|
|||||||
unit-test:
|
unit-test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
|
|
||||||
- run: npm ci
|
- run: npm ci
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/supported-version@main
|
- uses: graycoreio/github-actions-magento2/supported-version@main
|
||||||
id: supported-version
|
id: supported-version
|
||||||
- run: echo ${{ steps.supported-version.outputs.matrix }}
|
- run: echo ${{ steps.supported-version.outputs.matrix }}
|
||||||
|
|||||||
@@ -272,7 +272,7 @@ jobs:
|
|||||||
run: ../../../vendor/bin/phpunit -c phpunit.xml.dist --testsuite Extension_Integration_Tests
|
run: ../../../vendor/bin/phpunit -c phpunit.xml.dist --testsuite Extension_Integration_Tests
|
||||||
|
|
||||||
- name: Upload test sandbox dir
|
- name: Upload test sandbox dir
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v6
|
||||||
if: failure()
|
if: failure()
|
||||||
with:
|
with:
|
||||||
name: sandbox-data-${{ steps.magento-version.outputs.version }}
|
name: sandbox-data-${{ steps.magento-version.outputs.version }}
|
||||||
|
|||||||
@@ -8,9 +8,10 @@ See the [integration.yaml](./integration.yaml)
|
|||||||
|
|
||||||
| Input | Description | Required | Default |
|
| Input | Description | Required | Default |
|
||||||
| ------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------- | -------- | ----------------------------- |
|
| ------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------- | -------- | ----------------------------- |
|
||||||
| matrix | JSON string of [version matrix for Magento](./#matrix-format) | true | NULL |
|
| matrix | JSON string of [version matrix for Magento](./#matrix-format). Must include a `services` key (pass `include_services: true` to the supported-version action). | true | NULL |
|
||||||
| fail-fast | Same as Github's [fail-fast](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstrategyfail-fast) | false | true |
|
| fail-fast | Same as Github's [fail-fast](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstrategyfail-fast) | false | true |
|
||||||
| package_name | The name of the package | true | NULL |
|
| package_name | The name of the package | true | NULL |
|
||||||
|
| use_local_source | Whether or not you want to test your local package or not. | false | true |
|
||||||
| source_folder | The source folder of the package | false | $GITHUB_WORKSPACE |
|
| source_folder | The source folder of the package | false | $GITHUB_WORKSPACE |
|
||||||
| magento_directory | The folder where Magento will be installed | false | ../magento2 |
|
| magento_directory | The folder where Magento will be installed | false | ../magento2 |
|
||||||
| magento_repository | Where to install Magento from | false | https://mirror.mage-os.org/ |
|
| magento_repository | Where to install Magento from | false | https://mirror.mage-os.org/ |
|
||||||
@@ -46,10 +47,11 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/supported-version@main
|
- uses: graycoreio/github-actions-magento2/supported-version@main
|
||||||
|
with:
|
||||||
|
include_services: true
|
||||||
id: supported-version
|
id: supported-version
|
||||||
- run: echo ${{ steps.supported-version.outputs.matrix }}
|
|
||||||
integration-workflow:
|
integration-workflow:
|
||||||
needs: compute_matrix
|
needs: compute_matrix
|
||||||
uses: graycoreio/github-actions-magento2/.github/workflows/integration.yaml@main
|
uses: graycoreio/github-actions-magento2/.github/workflows/integration.yaml@main
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ jobs:
|
|||||||
fail-fast: ${{ inputs.fail-fast }}
|
fail-fast: ${{ inputs.fail-fast }}
|
||||||
matrix: ${{ fromJSON(inputs.matrix) }}
|
matrix: ${{ fromJSON(inputs.matrix) }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- name: Set PHP Version
|
- name: Set PHP Version
|
||||||
uses: shivammathur/setup-php@v2
|
uses: shivammathur/setup-php@v2
|
||||||
with:
|
with:
|
||||||
@@ -96,7 +96,7 @@ jobs:
|
|||||||
|
|
||||||
|
|
||||||
- name: "Cache Composer Packages"
|
- name: "Cache Composer Packages"
|
||||||
uses: actions/cache@v4
|
uses: actions/cache@v5
|
||||||
with:
|
with:
|
||||||
key: "composer | v5 | ${{ inputs.composer_cache_key }} | ${{ hashFiles('composer.lock') }} | ${{ matrix.os }} | ${{ matrix.composer }} | ${{ matrix.php }} | ${{ matrix.magento }}"
|
key: "composer | v5 | ${{ inputs.composer_cache_key }} | ${{ hashFiles('composer.lock') }} | ${{ matrix.os }} | ${{ matrix.composer }} | ${{ matrix.php }} | ${{ matrix.magento }}"
|
||||||
path: ${{ steps.composer-cache.outputs.dir }}
|
path: ${{ steps.composer-cache.outputs.dir }}
|
||||||
@@ -181,7 +181,7 @@ jobs:
|
|||||||
name: Run Integration Tests
|
name: Run Integration Tests
|
||||||
|
|
||||||
- name: Upload test sandbox dir
|
- name: Upload test sandbox dir
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v6
|
||||||
if: failure()
|
if: failure()
|
||||||
with:
|
with:
|
||||||
name: sandbox-data-${{ steps.magento-version.outputs.version }}
|
name: sandbox-data-${{ steps.magento-version.outputs.version }}
|
||||||
|
|||||||
@@ -9,8 +9,6 @@ jobs:
|
|||||||
release-please:
|
release-please:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: google-github-actions/release-please-action@v4
|
- uses: googleapis/release-please-action@v4
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GRAYCORE_GITHUB_TOKEN }}
|
token: ${{ secrets.GRAYCORE_GITHUB_TOKEN }}
|
||||||
command: manifest
|
|
||||||
default-branch: main
|
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
{".":"4.0.0"}
|
{".":"5.0.0"}
|
||||||
|
|||||||
@@ -2,6 +2,27 @@
|
|||||||
|
|
||||||
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
||||||
|
|
||||||
|
## [5.0.0](https://github.com/graycoreio/github-actions-magento2/compare/v4.0.1...v5.0.0) (2026-02-18)
|
||||||
|
|
||||||
|
|
||||||
|
### ⚠ BREAKING CHANGES
|
||||||
|
|
||||||
|
* remove unmaintained setup-di-compile action
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* remove unmaintained setup-di-compile action ([7b5ccf7](https://github.com/graycoreio/github-actions-magento2/commit/7b5ccf7d9d67da8c67e77b222b89b0abf332b183))
|
||||||
|
* use actions/cache@v5 ([86b01b1](https://github.com/graycoreio/github-actions-magento2/commit/86b01b17faf443802bdf827fdbb706c55ae7e3fb))
|
||||||
|
* use actions/checkout@v6 ([c2c3755](https://github.com/graycoreio/github-actions-magento2/commit/c2c375572967ee6ff8afc3a406b8d5a02880159e))
|
||||||
|
* use actions/upload-artifact@v6 ([5f3ba73](https://github.com/graycoreio/github-actions-magento2/commit/5f3ba73bc67a5c09e22f83c6e51421596103e0ce))
|
||||||
|
|
||||||
|
## [4.0.1](https://github.com/graycoreio/github-actions-magento2/compare/v4.0.0...v4.0.1) (2025-12-16)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **supported-version:** handle semver-ish values from old magento verisons ([7c0bc65](https://github.com/graycoreio/github-actions-magento2/commit/7c0bc65842e0e866cd957a44f879d37d04d11dce))
|
||||||
|
|
||||||
## [4.0.0](https://github.com/graycoreio/github-actions-magento2/compare/v3.0.0...v4.0.0) (2025-12-15)
|
## [4.0.0](https://github.com/graycoreio/github-actions-magento2/compare/v3.0.0...v4.0.0) (2025-12-15)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ jobs:
|
|||||||
showcase_cache:
|
showcase_cache:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/cache-magento@main
|
- uses: graycoreio/github-actions-magento2/cache-magento@main
|
||||||
with:
|
with:
|
||||||
mode: 'store'
|
mode: 'store'
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ runs:
|
|||||||
id: cache-magento-get-composer-version
|
id: cache-magento-get-composer-version
|
||||||
|
|
||||||
- name: "Cache Composer Packages"
|
- name: "Cache Composer Packages"
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v5
|
||||||
id: cache-magento-cache
|
id: cache-magento-cache
|
||||||
with:
|
with:
|
||||||
key: "composer | v5.8 | ${{ inputs.composer_cache_key }} | ${{ steps.cache-magento-get-composer-version.outputs.version }} | ${{ steps.cache-magento-get-php-version.outputs.version }}"
|
key: "composer | v5.8 | ${{ inputs.composer_cache_key }} | ${{ steps.cache-magento-get-composer-version.outputs.version }} | ${{ steps.cache-magento-get-php-version.outputs.version }}"
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ runs:
|
|||||||
using: composite
|
using: composite
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout head
|
- name: Checkout head
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v6
|
||||||
with:
|
with:
|
||||||
ref: ${{ inputs.head_ref }}
|
ref: ${{ inputs.head_ref }}
|
||||||
repository: ${{ inputs.head_repo }}
|
repository: ${{ inputs.head_repo }}
|
||||||
@@ -108,7 +108,7 @@ runs:
|
|||||||
|
|
||||||
- name: Checkout base
|
- name: Checkout base
|
||||||
if: steps.filter.outputs.phpcs == 'true'
|
if: steps.filter.outputs.phpcs == 'true'
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v6
|
||||||
with:
|
with:
|
||||||
ref: ${{github.event.pull_request.base.ref}}
|
ref: ${{github.event.pull_request.base.ref}}
|
||||||
repository: ${{github.event.pull_request.base.repo.full_name}}
|
repository: ${{github.event.pull_request.base.repo.full_name}}
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ runs:
|
|||||||
using: composite
|
using: composite
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Project
|
- name: Checkout Project
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v6
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
path: project
|
path: project
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ jobs:
|
|||||||
fix:
|
fix:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/fix-magento-install@main
|
- uses: graycoreio/github-actions-magento2/fix-magento-install@main
|
||||||
with:
|
with:
|
||||||
magento_directory: path/to/magento
|
magento_directory: path/to/magento
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: A job to compute an installed Composer version.
|
name: A job to compute an installed Composer version.
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/get-composer-version@main
|
- uses: graycoreio/github-actions-magento2/get-composer-version@main
|
||||||
id: get-composer-version
|
id: get-composer-version
|
||||||
- run: echo version ${{ steps.get-composer-version.outputs.version }}
|
- run: echo version ${{ steps.get-composer-version.outputs.version }}
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: A job to compute an installed Magento version.
|
name: A job to compute an installed Magento version.
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/get-magento-version@main
|
- uses: graycoreio/github-actions-magento2/get-magento-version@main
|
||||||
id: get-magento-version
|
id: get-magento-version
|
||||||
- run: echo version ${{ steps.get-magento-version.outputs.version }}
|
- run: echo version ${{ steps.get-magento-version.outputs.version }}
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
matrix: ${{ steps.supported-version.outputs.matrix }}
|
matrix: ${{ steps.supported-version.outputs.matrix }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/supported-version@main
|
- uses: graycoreio/github-actions-magento2/supported-version@main
|
||||||
id: supported-version
|
id: supported-version
|
||||||
- run: echo ${{ steps.supported-version.outputs.matrix }}
|
- run: echo ${{ steps.supported-version.outputs.matrix }}
|
||||||
@@ -36,7 +36,7 @@ jobs:
|
|||||||
matrix: ${{ fromJSON(needs.compute_matrix.outputs.matrix) }}
|
matrix: ${{ fromJSON(needs.compute_matrix.outputs.matrix) }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/installation-test@main
|
- uses: graycoreio/github-actions-magento2/installation-test@main
|
||||||
with:
|
with:
|
||||||
composer_version: ${{ matrix.composer }}
|
composer_version: ${{ matrix.composer }}
|
||||||
|
|||||||
@@ -89,7 +89,7 @@ runs:
|
|||||||
|
|
||||||
|
|
||||||
- name: "Cache Composer Packages"
|
- name: "Cache Composer Packages"
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v5
|
||||||
with:
|
with:
|
||||||
key: "composer | v5 | ${{ inputs.composer_cache_key }} | ${{ hashFiles('composer.lock') }} | ${{ runner.os }} | ${{ inputs.composer_version }} | ${{ inputs.php_version }} | ${{ inputs.magento_version }}"
|
key: "composer | v5 | ${{ inputs.composer_cache_key }} | ${{ hashFiles('composer.lock') }} | ${{ runner.os }} | ${{ inputs.composer_version }} | ${{ inputs.php_version }} | ${{ inputs.magento_version }}"
|
||||||
path: ${{ steps.composer-cache.outputs.dir }}
|
path: ${{ steps.composer-cache.outputs.dir }}
|
||||||
|
|||||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "@graycoreio/github-actions-magento2",
|
"name": "@graycoreio/github-actions-magento2",
|
||||||
"version": "4.0.0",
|
"version": "5.0.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "@graycoreio/github-actions-magento2",
|
"name": "@graycoreio/github-actions-magento2",
|
||||||
"version": "4.0.0",
|
"version": "5.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/core": "^1.11.1"
|
"@actions/core": "^1.11.1"
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@graycoreio/github-actions-magento2",
|
"name": "@graycoreio/github-actions-magento2",
|
||||||
"version": "4.0.0",
|
"version": "5.0.0",
|
||||||
"description": "Github Actions for Magento 2",
|
"description": "Github Actions for Magento 2",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "cd supported-version && npm run test && cd -",
|
"test": "cd supported-version && npm run test && cd -",
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: A job to semantically compare two versions
|
name: A job to semantically compare two versions
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/semver-compare@main
|
- uses: graycoreio/github-actions-magento2/semver-compare@main
|
||||||
with:
|
with:
|
||||||
version: 2.1.0
|
version: 2.1.0
|
||||||
|
|||||||
@@ -1,29 +0,0 @@
|
|||||||
# Magento 2 setup:di:compile action
|
|
||||||
A Github Action that runs `php bin/magento setup:di:compile` and checks for compilation errors.
|
|
||||||
|
|
||||||
## Inputs
|
|
||||||
|
|
||||||
See the [action.yml](./action.yml)
|
|
||||||
|
|
||||||
## Usage
|
|
||||||
|
|
||||||
```yml
|
|
||||||
name: Magento setup:di:compile check
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
setup-di-compile:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: graycoreio/github-actions-magento2/setup-di-compile@main
|
|
||||||
with:
|
|
||||||
php_version: "8.3"
|
|
||||||
composer_version: "2"
|
|
||||||
```
|
|
||||||
@@ -1,58 +0,0 @@
|
|||||||
name: "Magento compilation (setup:di:compile)"
|
|
||||||
author: "MageOS"
|
|
||||||
description: "A Github Action that runs bin/magento setup:di:compile."
|
|
||||||
|
|
||||||
inputs:
|
|
||||||
php_version:
|
|
||||||
required: true
|
|
||||||
default: "8.3"
|
|
||||||
description: "PHP version used to run setup:di:compile."
|
|
||||||
|
|
||||||
composer_version:
|
|
||||||
required: true
|
|
||||||
default: "2"
|
|
||||||
description: "The version of composer to use."
|
|
||||||
|
|
||||||
runs:
|
|
||||||
using: composite
|
|
||||||
steps:
|
|
||||||
- name: Checkout Project
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- name: Get changed files that could break compilation
|
|
||||||
uses: tj-actions/changed-files@v39
|
|
||||||
id: changed-files
|
|
||||||
with:
|
|
||||||
files_yaml: |
|
|
||||||
magento:
|
|
||||||
- 'composer.lock'
|
|
||||||
- 'composer.json'
|
|
||||||
- '**/*.php'
|
|
||||||
- '**/*.xml'
|
|
||||||
|
|
||||||
- name: Set PHP Version
|
|
||||||
if: steps.changed-files.outputs.magento_any_changed == 'true'
|
|
||||||
uses: shivammathur/setup-php@v2
|
|
||||||
with:
|
|
||||||
php-version: ${{ inputs.php_version }}
|
|
||||||
tools: composer:v${{ inputs.composer_version }}
|
|
||||||
coverage: none
|
|
||||||
|
|
||||||
- uses: graycoreio/github-actions-magento2/cache-magento@main
|
|
||||||
with:
|
|
||||||
mode: 'store'
|
|
||||||
|
|
||||||
- name: Install composer dependencies
|
|
||||||
if: steps.changed-files.outputs.magento_any_changed == 'true'
|
|
||||||
shell: bash
|
|
||||||
run: composer install
|
|
||||||
|
|
||||||
- name: Enable all modules
|
|
||||||
if: steps.changed-files.outputs.magento_any_changed == 'true'
|
|
||||||
shell: bash
|
|
||||||
run: php bin/magento module:enable --all
|
|
||||||
|
|
||||||
- name: Compile
|
|
||||||
if: steps.changed-files.outputs.magento_any_changed == 'true'
|
|
||||||
shell: bash
|
|
||||||
run: php bin/magento setup:di:compile
|
|
||||||
@@ -49,7 +49,7 @@ jobs:
|
|||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
|
|
||||||
- uses: graycoreio/github-actions-magento/setup-magento@main
|
- uses: graycoreio/github-actions-magento/setup-magento@main
|
||||||
id: setup-magento
|
id: setup-magento
|
||||||
@@ -87,7 +87,7 @@ jobs:
|
|||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
|
|
||||||
- uses: graycoreio/github-actions-magento/setup-magento@main
|
- uses: graycoreio/github-actions-magento/setup-magento@main
|
||||||
id: setup-magento
|
id: setup-magento
|
||||||
|
|||||||
Vendored
+21
-21
File diff suppressed because one or more lines are too long
@@ -39,4 +39,15 @@ describe('getUsableVersions for magento-open-source', () => {
|
|||||||
const versions = getUsableVersions(project);
|
const versions = getUsableVersions(project);
|
||||||
expect(versions).toContain('magento/project-community-edition:2.4.6');
|
expect(versions).toContain('magento/project-community-edition:2.4.6');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('should handle numeric composer versions', () => {
|
||||||
|
mockGetVersions.mockReturnValue({
|
||||||
|
'magento/project-community-edition:2.3.7-p3': { composer: 1 },
|
||||||
|
'magento/project-community-edition:2.4.6': { composer: 2 }
|
||||||
|
});
|
||||||
|
|
||||||
|
const versions = getUsableVersions(project);
|
||||||
|
expect(versions).not.toContain('magento/project-community-edition:2.3.7-p3');
|
||||||
|
expect(versions).toContain('magento/project-community-edition:2.4.6');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -12,7 +12,8 @@ export const getUsableVersions = (project: string): string[] => {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
// Packagist retired support for Composer 1 on 2025-09-01.
|
// Packagist retired support for Composer 1 on 2025-09-01.
|
||||||
if (value.composer && semver.lt(value.composer.toString(), '2.0.0')) {
|
const composerVersion = semver.coerce(value.composer.toString());
|
||||||
|
if (composerVersion && semver.lt(composerVersion, '2.0.0')) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -28,7 +28,7 @@ jobs:
|
|||||||
- 8.1
|
- 8.1
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v6
|
||||||
- uses: graycoreio/github-actions-magento2/unit-test@main
|
- uses: graycoreio/github-actions-magento2/unit-test@main
|
||||||
with:
|
with:
|
||||||
php_version: ${{ matrix.php_version }}
|
php_version: ${{ matrix.php_version }}
|
||||||
|
|||||||
Reference in New Issue
Block a user