From 9147790326e1db2c5e9a19d59321d1f3a8813d40 Mon Sep 17 00:00:00 2001 From: Wilmer Arambula Date: Tue, 29 Aug 2023 09:56:56 -0400 Subject: [PATCH 1/2] Update workflows. --- .github/workflows/build.yml | 20 ++++++++++++++++++-- .github/workflows/ci-mssql.yml | 18 ++++++++++++++++-- .github/workflows/ci-mysql.yml | 18 ++++++++++++++++-- .github/workflows/ci-node.yml | 20 ++++++++++++++++++-- .github/workflows/ci-oracle.yml | 18 ++++++++++++++++-- .github/workflows/ci-pgsql.yml | 18 ++++++++++++++++-- .github/workflows/ci-sqlite.yml | 18 ++++++++++++++++-- 7 files changed, 116 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 30b988edb4f..2ef2afc124a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,6 +1,22 @@ -name: build +on: + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' -on: [push, pull_request] +name: build env: DEFAULT_COMPOSER_FLAGS: "--prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi" diff --git a/.github/workflows/ci-mssql.yml b/.github/workflows/ci-mssql.yml index 94255d93ebe..2b0c9c3cd25 100644 --- a/.github/workflows/ci-mssql.yml +++ b/.github/workflows/ci-mssql.yml @@ -1,6 +1,20 @@ on: - - pull_request - - push + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' name: ci-mssql diff --git a/.github/workflows/ci-mysql.yml b/.github/workflows/ci-mysql.yml index a948a9e4cae..565154323fc 100644 --- a/.github/workflows/ci-mysql.yml +++ b/.github/workflows/ci-mysql.yml @@ -1,6 +1,20 @@ on: - - pull_request - - push + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' name: ci-mysql diff --git a/.github/workflows/ci-node.yml b/.github/workflows/ci-node.yml index 0d937733554..2b5d18e6dfe 100644 --- a/.github/workflows/ci-node.yml +++ b/.github/workflows/ci-node.yml @@ -1,6 +1,22 @@ -name: build-node +on: + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' -on: [push, pull_request] +name: build-node env: DEFAULT_COMPOSER_FLAGS: "--prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi" diff --git a/.github/workflows/ci-oracle.yml b/.github/workflows/ci-oracle.yml index 21520a1045b..fa80652ea53 100644 --- a/.github/workflows/ci-oracle.yml +++ b/.github/workflows/ci-oracle.yml @@ -1,6 +1,20 @@ on: - - pull_request - - push + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' name: ci-oracle diff --git a/.github/workflows/ci-pgsql.yml b/.github/workflows/ci-pgsql.yml index edaf4a5df5d..b574d79205c 100644 --- a/.github/workflows/ci-pgsql.yml +++ b/.github/workflows/ci-pgsql.yml @@ -1,6 +1,20 @@ on: - - pull_request - - push + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' name: ci-pgsql diff --git a/.github/workflows/ci-sqlite.yml b/.github/workflows/ci-sqlite.yml index b82d187ef9a..08843130668 100644 --- a/.github/workflows/ci-sqlite.yml +++ b/.github/workflows/ci-sqlite.yml @@ -1,6 +1,20 @@ on: - - pull_request - - push + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' name: ci-sqlite From 1a9dd7f9d5bc0108037bf981e25e967c7e3350ea Mon Sep 17 00:00:00 2001 From: Wilmer Arambula Date: Thu, 5 Oct 2023 09:17:59 -0300 Subject: [PATCH 2/2] Improve remove duplicate tests in CI. --- .github/workflows/build.yml | 4 +++- .github/workflows/ci-mssql.yml | 6 ++++-- .github/workflows/ci-mysql.yml | 7 +++++-- .github/workflows/ci-node.yml | 6 ++++-- .github/workflows/ci-oracle.yml | 6 ++++-- .github/workflows/ci-pgsql.yml | 7 +++++-- .github/workflows/ci-sqlite.yml | 6 ++++-- 7 files changed, 29 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2ef2afc124a..236363ddeef 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -29,6 +28,9 @@ concurrency: jobs: phpunit: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: PHP ${{ matrix.php }} on ${{ matrix.os }} runs-on: ${{ matrix.os }} diff --git a/.github/workflows/ci-mssql.yml b/.github/workflows/ci-mssql.yml index 2b0c9c3cd25..834bcc27d80 100644 --- a/.github/workflows/ci-mssql.yml +++ b/.github/workflows/ci-mssql.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -23,7 +22,10 @@ concurrency: cancel-in-progress: true jobs: - tests: + ci-mssql: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: PHP ${{ matrix.php }}-mssql-${{ matrix.mssql }} env: diff --git a/.github/workflows/ci-mysql.yml b/.github/workflows/ci-mysql.yml index 565154323fc..5dd78ccf8f8 100644 --- a/.github/workflows/ci-mysql.yml +++ b/.github/workflows/ci-mysql.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -23,8 +22,12 @@ concurrency: cancel-in-progress: true jobs: - tests: + ci-mysql: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: PHP ${{ matrix.php }}-mysql-${{ matrix.mysql }} + env: extensions: curl, intl, pdo, pdo_mysql XDEBUG_MODE: coverage, develop diff --git a/.github/workflows/ci-node.yml b/.github/workflows/ci-node.yml index 2b5d18e6dfe..928550359a3 100644 --- a/.github/workflows/ci-node.yml +++ b/.github/workflows/ci-node.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -26,7 +25,10 @@ concurrency: cancel-in-progress: true jobs: - test: + ci-node: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: NPM 6 on ubuntu-latest runs-on: ubuntu-latest diff --git a/.github/workflows/ci-oracle.yml b/.github/workflows/ci-oracle.yml index fa80652ea53..d3bef0fdad1 100644 --- a/.github/workflows/ci-oracle.yml +++ b/.github/workflows/ci-oracle.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -23,7 +22,10 @@ concurrency: cancel-in-progress: true jobs: - tests: + ci-oracle: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: PHP ${{ matrix.php }}-${{ matrix.os }} env: diff --git a/.github/workflows/ci-pgsql.yml b/.github/workflows/ci-pgsql.yml index b574d79205c..f3308bd9acc 100644 --- a/.github/workflows/ci-pgsql.yml +++ b/.github/workflows/ci-pgsql.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -23,8 +22,12 @@ concurrency: cancel-in-progress: true jobs: - tests: + ci-pgsql: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: PHP ${{ matrix.php }}-pgsql-${{ matrix.pgsql }} + env: extensions: curl, intl, pdo, pdo_pgsql XDEBUG_MODE: coverage, develop diff --git a/.github/workflows/ci-sqlite.yml b/.github/workflows/ci-sqlite.yml index 08843130668..00e22b6a979 100644 --- a/.github/workflows/ci-sqlite.yml +++ b/.github/workflows/ci-sqlite.yml @@ -8,7 +8,6 @@ on: - '.gitattributes' push: - branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -23,7 +22,10 @@ concurrency: cancel-in-progress: true jobs: - tests: + ci-sqlite: + # This workflow file runs actions for forked repositories, pull requests, and pushes to the master branch. + if: github.event.repository.fork == true || github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/master') + name: PHP ${{ matrix.php }}-sqlite env: