From 4560bc81e7dd8eb0f283580c85437ccff539d997 Mon Sep 17 00:00:00 2001 From: Kevin Wenger Date: Tue, 18 Oct 2022 14:56:18 +0200 Subject: [PATCH 1/5] update action actions/checkout v1 => v3 --- .github/workflows/ci.yml | 2 +- .github/workflows/styles.yml | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3129ff3..6b14297 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,7 +52,7 @@ jobs: experimental: true steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - run: docker-compose -f docker-compose.yml pull --include-deps drupal - name: Build the docker-compose stack run: docker-compose -f docker-compose.yml build --pull --build-arg BASE_IMAGE_TAG=${{ matrix.drupal_version }} drupal diff --git a/.github/workflows/styles.yml b/.github/workflows/styles.yml index e014a87..05a9bc1 100644 --- a/.github/workflows/styles.yml +++ b/.github/workflows/styles.yml @@ -6,7 +6,7 @@ jobs: name: eslint runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Install modules run: yarn - name: Run ESLint @@ -16,7 +16,7 @@ jobs: name: prettier runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Install modules run: yarn - name: Run Prettier @@ -32,7 +32,7 @@ jobs: php-version: '7.3' extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv tools: cs2pr, composer:v1 - - uses: actions/checkout@master + - uses: actions/checkout@v3 - run: composer install --prefer-dist - run: ./vendor/bin/phpcs ./ --report=checkstyle | cs2pr @@ -46,7 +46,7 @@ jobs: php-version: '7.3' extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv tools: cs2pr, composer:v1, phpmd - - uses: actions/checkout@master + - uses: actions/checkout@v3 - run: composer install --prefer-dist - run: phpmd ./ text ./phpmd.xml --suffixes php,module,inc,install,test,profile,theme,css,info,txt --exclude *Test.php,*vendor/* @@ -60,7 +60,7 @@ jobs: php-version: '7.3' extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv tools: cs2pr, composer:v1, phpcpd - - uses: actions/checkout@master + - uses: actions/checkout@v3 - run: composer install --prefer-dist - run: phpcpd ./src --suffix .php --suffix .module --suffix .inc --suffix .install --suffix .test --suffix .profile --suffix .theme --suffix .css --suffix .info --suffix .txt --exclude *.md --exclude *.info.yml --exclude tests --exclude vendor/ @@ -68,7 +68,7 @@ jobs: name: PhpDeprecationDetector (phpdd) runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - run: docker-compose -f docker-compose.yml pull --include-deps drupal - name: Build the docker-compose stack run: docker-compose -f docker-compose.yml build drupal From 105692c3deb123e7de246e98a93b5efbb65d8fb6 Mon Sep 17 00:00:00 2001 From: Kevin Wenger Date: Tue, 18 Oct 2022 14:56:36 +0200 Subject: [PATCH 2/5] add upgrade-status check --- .github/workflows/ci.yml | 30 ++++++++++++++++++++++++++++++ CHANGELOG.md | 1 + 2 files changed, 31 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6b14297..cad5c65 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -72,3 +72,33 @@ jobs: run: docker-compose -f docker-compose.yml exec -T -u www-data drupal phpunit --no-coverage --group=${{ matrix.module }}_functional --configuration=/var/www/html/phpunit.xml --fail-on-risky continue-on-error: ${{ matrix.experimental }} + upgrade-status: + name: Upgrade Status + runs-on: ubuntu-latest + + strategy: + matrix: + drupal_version: ['9.4'] + module: ['nbsp'] + + steps: + - uses: actions/checkout@v3 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + - run: docker-compose -f docker-compose.yml pull --include-deps drupal + - name: Build the docker-compose stack + run: docker-compose -f docker-compose.yml build --pull --build-arg BASE_IMAGE_TAG=${{ matrix.drupal_version }} drupal + - name: Up a persistent Docker Container + run: docker-compose -f docker-compose.yml up -d drupal + - name: Add upgrade status dependency + run: docker-compose exec -T drupal wait-for-it db:3306 -- composer require --dev drupal/upgrade_status --no-interaction + - name: Bootstrap Drupal + run: docker-compose -f docker-compose.yml exec -T -u www-data drupal drush site-install standard --db-url="mysql://drupal:drupal@db/drupal" -y + - name: Enable upgrade status + run: docker-compose exec -T drupal wait-for-it db:3306 -- ./vendor/bin/drush en upgrade_status -y + - name: Disable incompatible module + run: docker-compose exec -T drupal wait-for-it db:3306 -- ./vendor/bin/drush pmu page_cache -y + - name: Enable the module + run: docker-compose exec -T drupal wait-for-it db:3306 -- ./vendor/bin/drush en ${{ matrix.module }} -y + - name: Run upgrade status + run: docker-compose exec -T drupal wait-for-it db:3306 -- ./vendor/bin/drush upgrade_status:analyze ${{ matrix.module }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 00a1676..b40adb1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] ### Added - add dependabot for GitHub Action dependency +- add upgrade-status check ### Changed - disable deprecation notice PHPUnit From 503dcd3a348b49561737808d8ee22082bbbeb66d Mon Sep 17 00:00:00 2001 From: Kevin Wenger Date: Tue, 18 Oct 2022 15:00:40 +0200 Subject: [PATCH 3/5] drop support of drupal 8.8 & 8.9 --- .github/workflows/ci.yml | 4 ++-- CHANGELOG.md | 1 + Dockerfile | 2 +- README.md | 12 +++++++----- nbsp.info.yml | 2 +- 5 files changed, 12 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cad5c65..2456188 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,7 +12,7 @@ jobs: strategy: matrix: - drupal_version: ['8.8', '8.9', '9.0', '9.1', '9.2'] + drupal_version: ['9.0', '9.1', '9.2'] module: ['nbsp'] experimental: [ false ] include: @@ -43,7 +43,7 @@ jobs: strategy: matrix: - drupal_version: ['8.8', '8.9', '9.0', '9.1', '9.2'] + drupal_version: ['9.0', '9.1', '9.2'] module: [ 'nbsp' ] experimental: [ false ] include: diff --git a/CHANGELOG.md b/CHANGELOG.md index b40adb1..b4654df 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed - disable deprecation notice PHPUnit - update changelog form to follow keep-a-changelog format +- drop support of drupal 8.8 & 8.9 ### Removed - remove satackey/action-docker-layer-caching on Github Actions diff --git a/Dockerfile b/Dockerfile index b622177..6713091 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -ARG BASE_IMAGE_TAG=8.9 +ARG BASE_IMAGE_TAG=9.0 FROM wengerk/drupal-for-contrib:${BASE_IMAGE_TAG} # Disable deprecation notice because supporting both Drupal 8 & Drupal 9. diff --git a/README.md b/README.md index 760c6c5..ffba11c 100644 --- a/README.md +++ b/README.md @@ -40,13 +40,15 @@ The version `8.x-1.x` is not compatible with Drupal `8.8.x`. Drupal `8.8.x` brings some breaking change with tests and so you must upgrade to `8.x-2.x` version of **NBSP**. +The version `8.x-3.x` is not compatible with Drupal `8.x` and will only support Drupal `9.x` Drupal `10.x`. + ## Which version should I use? -|Drupal Core|NBSP | -|:---------:|:----------:| -|8.7.x |1.x | -|8.8.x |2.x | -|9.x |2.x | +|Drupal Core| NBSP | +|:---------:|:---------:| +|8.7.x | 1.x | +|8.8.x | 2.x | +|9.x | 2.x - 3.x | ## Dependencies diff --git a/nbsp.info.yml b/nbsp.info.yml index 2c9b481..acbe4c3 100644 --- a/nbsp.info.yml +++ b/nbsp.info.yml @@ -1,7 +1,7 @@ name: 'CKEditor Non-breaking space Plugin' type: module description: 'Minimal module to insert a non-breaking space into the content by pressing Ctrl+Space or using the provided button.' -core_version_requirement: ^8.8 || ^9 +core_version_requirement: ^9 package: CKEditor dependencies: From 9cc2a2e96950294e1c79066b1b2f427bddf9e87b Mon Sep 17 00:00:00 2001 From: Kevin Wenger Date: Tue, 18 Oct 2022 15:02:45 +0200 Subject: [PATCH 4/5] add coverage for Drupal 9.3, 9.4 & 9.5 --- .github/workflows/ci.yml | 8 ++++---- CHANGELOG.md | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2456188..f8e2b22 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,11 +12,11 @@ jobs: strategy: matrix: - drupal_version: ['9.0', '9.1', '9.2'] + drupal_version: ['9.0', '9.1', '9.2', '9.3', '9.4', '9.5'] module: ['nbsp'] experimental: [ false ] include: - - drupal_version: '9.3' + - drupal_version: '9.5' module: 'nbsp' experimental: true @@ -43,11 +43,11 @@ jobs: strategy: matrix: - drupal_version: ['9.0', '9.1', '9.2'] + drupal_version: ['9.0', '9.1', '9.2', '9.3', '9.4', '9.5'] module: [ 'nbsp' ] experimental: [ false ] include: - - drupal_version: '9.3' + - drupal_version: '9.5' module: 'nbsp' experimental: true diff --git a/CHANGELOG.md b/CHANGELOG.md index b4654df..c0a64c3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - add dependabot for GitHub Action dependency - add upgrade-status check +- add coverage for Drupal 9.3, 9.4 & 9.5 ### Changed - disable deprecation notice PHPUnit From 58fdeecee193308cb5f490b7474ef9c039b97be6 Mon Sep 17 00:00:00 2001 From: Kevin Wenger Date: Tue, 18 Oct 2022 15:03:07 +0200 Subject: [PATCH 5/5] update action php-version 7.3 => 7.4 --- .github/workflows/styles.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/styles.yml b/.github/workflows/styles.yml index 05a9bc1..d0ed383 100644 --- a/.github/workflows/styles.yml +++ b/.github/workflows/styles.yml @@ -29,7 +29,7 @@ jobs: - name: Setup PHP uses: shivammathur/setup-php@v2 with: - php-version: '7.3' + php-version: '7.4' extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv tools: cs2pr, composer:v1 - uses: actions/checkout@v3 @@ -43,7 +43,7 @@ jobs: - name: Setup PHP uses: shivammathur/setup-php@v2 with: - php-version: '7.3' + php-version: '7.4' extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv tools: cs2pr, composer:v1, phpmd - uses: actions/checkout@v3 @@ -57,7 +57,7 @@ jobs: - name: Setup PHP uses: shivammathur/setup-php@v2 with: - php-version: '7.3' + php-version: '7.4' extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv tools: cs2pr, composer:v1, phpcpd - uses: actions/checkout@v3