Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 37 additions & 11 deletions .github/workflows/plugin-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,47 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Build clean plugin directory
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'

- name: Build plugin directory
run: |
mkdir -p plugin-build/warder-cookie-consent
rsync -a --exclude='.git' --exclude-from='.distignore' . plugin-build/warder-cookie-consent/

- name: Install wp-env
run: npm install -g @wordpress/env

- name: Create wp-env config
run: |
mkdir -p ${{ github.workspace }}/plugin-build/warder-cookie-consent
rsync -a --exclude='.git' --exclude-from='.distignore' . ${{ github.workspace }}/plugin-build/warder-cookie-consent/
echo '{
"core": null,
"plugins": [
"https://downloads.wordpress.org/plugin/plugin-check.zip",
"./plugin-build/warder-cookie-consent"
]
}' > .wp-env.json

- name: Start wp-env
run: wp-env start
timeout-minutes: 5

- name: Run Plugin Check
uses: WordPress/plugin-check-action@v1
with:
build-dir: '${{ github.workspace }}/plugin-build/warder-cookie-consent'
checks: ''
exclude-checks: 'EnqueuedScriptsScope'
run: |
wp-env run cli wp plugin check warder-cookie-consent \
--exclude-checks=EnqueuedScriptsScope \
--format=table \
| tee plugin-check-results.txt

- name: Upload Plugin Check Results
uses: actions/upload-artifact@v4
- name: Upload Plugin Check results
if: always()
uses: actions/upload-artifact@v4
with:
name: plugin-check-results
path: ${{ github.workspace }}/plugin-build/warder-cookie-consent/plugin-check-results.txt
path: plugin-check-results.txt

- name: Stop wp-env
if: always()
run: wp-env stop
19 changes: 13 additions & 6 deletions .github/workflows/wpcs.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,21 @@
name: WPCS check
name: WPCS Check

on: pull_request

jobs:
phpcs:
name: WPCS
name: WPCS Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: WPCS check
uses: 10up/wpcs-action@stable
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
standard: 'WordPress'
php-version: '8.2'

- name: Install dependencies
run: composer install --no-progress --prefer-dist

- name: Run PHP_CodeSniffer
run: vendor/bin/phpcs --standard=phpcs.xml --warning-severity=0
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

All notable changes to Warder Cookie Consent are documented here.

## [1.4.1] - 2026-05-27

### Changed
- Replaced the `10up/wpcs-action`-based WPCS workflow with a local PHPCS workflow that runs against `phpcs.xml` — enforces `WordPress.WP.I18n` with the `warder-cookie-consent` text domain and `WordPress.Security.EscapeOutput`, catching i18n and escaping issues the old workflow missed

## [1.4.0] - 2026-05-27

### Added
Expand Down
10 changes: 9 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Donate link: https://imagewize.com
Tags: cookie, consent, gdpr, privacy, compliance
Requires at least: 5.0
Tested up to: 7.0
Stable tag: 1.4.0
Stable tag: 1.4.1
Requires PHP: 8.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Expand Down Expand Up @@ -72,6 +72,11 @@ Yes. Settings are versioned via a timestamp that is appended to the script URL,

== Changelog ==

= 1.4.1 =
*2026-05-27*

* Changed: Replaced the 10up/wpcs-action workflow with a local PHPCS workflow using phpcs.xml, adding enforcement of WordPress.WP.I18n (text domain: warder-cookie-consent) and WordPress.Security.EscapeOutput on pull requests

= 1.4.0 =
*2026-05-27*

Expand Down Expand Up @@ -142,6 +147,9 @@ Yes. Settings are versioned via a timestamp that is appended to the script URL,

== Upgrade Notice ==

= 1.4.1 =
Replaces the 10up/wpcs-action CI workflow with local PHPCS, adding strict i18n (text domain) and output escaping checks on pull requests.

= 1.4.0 =
Restores the category/cookie management buttons (add/remove category and cookie) that were not working, with nonce-protected handlers. Adds minimum WordPress/PHP version headers.

Expand Down
2 changes: 1 addition & 1 deletion warder-cookie-consent.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/**
* Plugin Name: Warder Cookie Consent
* Description: GDPR-compliant cookie consent banner with category management and floating preferences toggle.
* Version: 1.4.0
* Version: 1.4.1
* Author: Jasper Frumau
* Author URI: https://imagewize.com
* Requires at least: 5.0
Expand Down
Loading