Skip to content

WordPress Tested Up To #2

WordPress Tested Up To

WordPress Tested Up To #2

# This workflow keeps WordPress "Tested up to" metadata current.
# It scans tracked PHP, Markdown, and text files without assuming repository-specific
# metadata filenames, then opens a pull request when values need to be updated to
# the latest WordPress major.minor release.
name: WordPress Tested Up To
on:
schedule:
- cron: '23 12 * * *'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: write
pull-requests: write
jobs:
tested-up-to:
name: Update Tested Up To Metadata
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Download WordPress version data
run: |
curl --fail --silent --show-error --location \
--proto '=https' --tlsv1.2 \
https://api.wordpress.org/core/version-check/1.7/ \
--output wordpress-version-check.json
- name: Update WordPress Tested Up To metadata
run: python3 .github/scripts/check-wordpress-tested-up-to.py --fix
- name: Remove downloaded version data
run: rm -f wordpress-version-check.json
- name: Check for changes
id: changes
run: |
if git diff --quiet; then
echo "has_changes=false" >> "$GITHUB_OUTPUT"
echo "WordPress Tested up to metadata is up to date"
else
echo "has_changes=true" >> "$GITHUB_OUTPUT"
echo "WordPress Tested up to metadata was updated"
git diff --name-only
fi
- name: Create Pull Request
if: steps.changes.outputs.has_changes == 'true'
uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8
with:
commit-message: 'chore: update WordPress Tested up to metadata'
title: 'chore: Update WordPress Tested up to metadata'
body: |
## WordPress Tested Up To Update
This PR updates the plugin metadata to match the latest WordPress major.minor release reported by WordPress.org.
See the diff in this PR for details.
---
*This PR was automatically generated by the [WordPress Tested Up To](https://github.com/${{ github.repository }}/blob/main/.github/workflows/wordpress-tested-up-to.yml) workflow.*
branch: chore/update-wordpress-tested-up-to
base: main
delete-branch: true
labels: 'automation,maintenance'