# Plugin Release Pipeline

This repository uses a GitHub Actions workflow to validate plugin release metadata on pull requests to `main` and to publish the plugin to the WordPress SVN repository after a merge lands on `main`.

## What the workflow checks

- The plugin header version in `seo-worker-ai.php`
- The runtime constant in `seo-worker-ai.php`
- The WordPress stable tag in `readme.txt`
- The first changelog entry in `readme.txt`
- The translation catalog version in `languages/seo-worker-ai.pot`
- That the release version is newer than the version on `main`

## What runs on merge to `main`

- The workflow uses the merge commit message as the SVN commit message.
- The plugin files are synced into the SVN checkout.
- A `tags/<version>` copy is created for the release version.

## Required GitHub settings

GitHub branch protection still has to be configured in the repository settings.

Recommended settings for `main`:

- Require pull request reviews before merging
- Require the `validate_release` status check
- Block direct pushes by restricting who can push to the branch
- Prevent force pushes
- Prevent branch deletion

## Required secrets

Set these repository secrets for the SVN publish step:

- `SVN_REPOSITORY_URL`
- `SVN_USERNAME`
- `SVN_PASSWORD`

