diff --git a/.circleci/config.yml b/.circleci/config.yml index 1cd5e74..d4a2400 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -102,6 +102,7 @@ jobs: - run: name: "Install Extras" command: | + sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4EB27DB2A3B88B8B sudo apt-get update sudo apt-get install subversion sudo apt-get install -y libmagickwand-dev --no-install-recommends @@ -141,6 +142,7 @@ jobs: - run: name: "Install Extras" command: | + sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4EB27DB2A3B88B8B sudo apt-get update sudo apt-get install subversion sudo apt-get install -y libmagickwand-dev --no-install-recommends diff --git a/.distignore b/.distignore deleted file mode 100644 index a2c3490..0000000 --- a/.distignore +++ /dev/null @@ -1,41 +0,0 @@ -# A set of files you probably don't want in your WordPress.org distribution -.babelrc -.deployignore -.distignore -.editorconfig -.eslintignore -.eslintrc -.git -.gitignore -.gitlab-ci.yml -.travis.yml -.DS_Store -Thumbs.db -behat.yml -bitbucket-pipelines.yml -bin -.circleci/config.yml -composer.json -composer.lock -dependencies.yml -Gruntfile.js -package.json -package-lock.json -phpunit.xml -phpunit.xml.dist -multisite.xml -multisite.xml.dist -.phpcs.xml -phpcs.xml -.phpcs.xml.dist -phpcs.xml.dist -README.md -webpack.config.js -wp-cli.local.yml -yarn.lock -tests -vendor -node_modules -*.sql -*.tar.gz -*.zip diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..a2ea1d8 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,27 @@ +# Directories +/.circleci export-ignore +/.git export-ignore +/.github export-ignore +/.wordpress-org export-ignore +/tests export-ignore +/node_modules export-ignore +/vendor export-ignore +/bin export-ignore + +# Files +/.DS_Store export-ignore +/Thumbs.db export-ignore +/.editorconfig export-ignore +/.gitattributes export-ignore +/.gitignore export-ignore +/behat.yml export-ignore +/CODEOWNERS export-ignore +/composer.json export-ignore +/composer.lock export-ignore +/CONTRIBUTING.md export-ignore +/Gruntfile.js export-ignore +/package-lock.json export-ignore +/package.json export-ignore +/phpcs.xml.dist export-ignore +/phpunit.xml.dist export-ignore +/README.md export-ignore \ No newline at end of file diff --git a/.github/workflows/wordpress-plugin-deploy.yml b/.github/workflows/wordpress-plugin-deploy.yml new file mode 100644 index 0000000..c8e29dd --- /dev/null +++ b/.github/workflows/wordpress-plugin-deploy.yml @@ -0,0 +1,16 @@ +name: Release wp-redis plugin to wp.org +on: + release: + types: [published] + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: WordPress Plugin Deploy + uses: 10up/action-wordpress-plugin-deploy@2.1.1 + env: + SVN_USERNAME: ${{ secrets.SVN_USERNAME }} + SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }} + SLUG: ${{ env.SLUG }} diff --git a/.wordpress-org/banner-1544x500.png b/.wordpress-org/banner-1544x500.png new file mode 100644 index 0000000..0126ef0 Binary files /dev/null and b/.wordpress-org/banner-1544x500.png differ diff --git a/.wordpress-org/banner-772x250.png b/.wordpress-org/banner-772x250.png new file mode 100644 index 0000000..186d2ca Binary files /dev/null and b/.wordpress-org/banner-772x250.png differ diff --git a/.wordpress-org/icon-128x128.png b/.wordpress-org/icon-128x128.png new file mode 100644 index 0000000..0b082ca Binary files /dev/null and b/.wordpress-org/icon-128x128.png differ diff --git a/.wordpress-org/icon-256x256.png b/.wordpress-org/icon-256x256.png new file mode 100644 index 0000000..715a3af Binary files /dev/null and b/.wordpress-org/icon-256x256.png differ diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..3a52d94 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,37 @@ +## Contributing ## + +The best way to contribute to the development of this plugin is by participating on the GitHub project: + +https://github.com/pantheon-systems/wp-redis + +Pull requests and issues are welcome! + +## Workflow + +The `develop` branch is the development branch which means it contains the next version to be released. `master` contains the corresponding stable development version. Always work on the `develop` branch and open up PRs against `develop`. + +## Testing + +You may notice there are two sets of tests running, on two different services: + +* The [PHPUnit](https://phpunit.de/) test suite. +* The [Behat](http://behat.org/) test suite runs against a Pantheon site, to ensure the plugin's compatibility with the Pantheon platform. + +Both of these test suites can be run locally, with a varying amount of setup. + +PHPUnit requires the [WordPress PHPUnit test suite](https://make.wordpress.org/core/handbook/testing/automated-testing/phpunit/), and access to a database with name `wordpress_test`. If you haven't already configured the test suite locally, you can run `bash bin/install-wp-tests.sh wordpress_test root '' localhost`. You'll also need to enable Redis and the PHPRedis extension in order to run the test suite against Redis. + +Behat requires a Pantheon site with Redis enabled. Once you've created the site, you'll need [install Terminus](https://github.com/pantheon-systems/terminus#installation), and set the `TERMINUS_TOKEN`, `TERMINUS_SITE`, and `TERMINUS_ENV` environment variables. Then, you can run `./bin/behat-prepare.sh` to prepare the site for the test suite. + +## Release Process + +1. Starting from `develop`, cut a release branch named `release_X.Y.Z` containing your changes. +1. Update plugin version in `package.json`, `README.md`, `readme.txt`, and `wp-redis.php`. +1. Update the Changelog with the latest changes. +1. Create a PR against the `master` branch. +1. After all tests pass and you have received approval from a CODEOWNER (including resolving any merge conflicts), merge the PR into `master`. +1. Pull `master` locally, create a new tag, and push up. +1. Confirm that the necessary assets are present in the newly created tag, and test on a WP install if desired. +1. Create a [new release](https://github.com/pantheon-systems/wp-redis/releases/new) using the tag created in the previous steps, naming the release with the new version number, and targeting the tag created in the previous step. Paste the release changelog from the `Changelog` section of the `README` into the body of the release and include a link to the closed issues if applicable. +1. Wait for the [_Release wp-redis plugin to wp.org_ action](https://github.com/pantheon-systems/wp-redis/actions/workflows/wordpress-plugin-deploy.yml) to finish deploying to the WordPress.org repository. If all goes well, users with SVN commit access for that plugin will receive an emailed diff of changes. +1. Check WordPress.org: Ensure that the changes are live on https://wordpress.org/plugins/wp-redis/. This may take a few minutes. \ No newline at end of file diff --git a/README.md b/README.md index b0cbff4..41599ff 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ **Tags:** cache, plugin, redis **Requires at least:** 3.0.1 **Tested up to:** 5.9 -**Stable tag:** 1.2.0 +**Stable tag:** 1.3.0 **License:** GPLv2 or later **License URI:** http://www.gnu.org/licenses/gpl-2.0.html @@ -78,22 +78,7 @@ Use `wp help redis ` to learn more about each command. ## Contributing ## -The best way to contribute to the development of this plugin is by participating on the GitHub project: - -https://github.com/pantheon-systems/wp-redis - -Pull requests and issues are welcome! - -You may notice there are two sets of tests running, on two different services: - -* Travis CI runs the [PHPUnit](https://phpunit.de/) test suite in a variety of environment configurations (e.g. Redis enabled vs. Redis disabled). -* Circle CI runs the [Behat](http://behat.org/) test suite against a Pantheon site, to ensure the plugin's compatibility with the Pantheon platform. - -Both of these test suites can be run locally, with a varying amount of setup. - -PHPUnit requires the [WordPress PHPUnit test suite](https://make.wordpress.org/core/handbook/testing/automated-testing/phpunit/), and access to a database with name `wordpress_test`. If you haven't already configured the test suite locally, you can run `bash bin/install-wp-tests.sh wordpress_test root '' localhost`. You'll also need to enable Redis and the PHPRedis extension in order to run the test suite against Redis. - -Behat requires a Pantheon site with Redis enabled. Once you've created the site, you'll need [install Terminus](https://github.com/pantheon-systems/terminus#installation), and set the `TERMINUS_TOKEN`, `TERMINUS_SITE`, and `TERMINUS_ENV` environment variables. Then, you can run `./bin/behat-prepare.sh` to prepare the site for the test suite. +See [CONTRIBUTING.md](https://github.com/pantheon-systems/wp-redis/blob/master/CONTRIBUTING.md) for information on contributing. ## Frequently Asked Questions ## @@ -119,6 +104,9 @@ There's a known issue with WordPress `alloptions` cache design. Specifically, a ## Changelog ## +### 1.3.0 (November 29th, 2022) ### +* Added CONTRIBUTING.MD and GitHub action to automate deployments to wp.org. [[#368](https://github.com/pantheon-systems/wp-redis/pull/368)] + ### 1.2.0 (February 17, 2022) ### * Adds support for Relay via `WP_REDIS_USE_RELAY` constant [[#344](https://github.com/pantheon-systems/wp-redis/pull/344)]. diff --git a/package-lock.json b/package-lock.json index 67e2f9d..1bdab98 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "wp-redis", - "version": "0.2.2", + "version": "1.3.0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 44605eb..b1c5c84 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wp-redis", - "version": "0.2.2", + "version": "1.3.0", "repository": { "type": "git", "url": "https://github.com/pantheon-systems/wp-redis.git" diff --git a/readme.txt b/readme.txt index bd57ff6..3feea78 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: getpantheon, danielbachhuber, mboynes, Outlandish Josh Tags: cache, plugin, redis Requires at least: 3.0.1 Tested up to: 5.9 -Stable tag: 1.2.0 +Stable tag: 1.3.0 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html @@ -76,22 +76,7 @@ Use `wp help redis ` to learn more about each command. == Contributing == -The best way to contribute to the development of this plugin is by participating on the GitHub project: - -https://github.com/pantheon-systems/wp-redis - -Pull requests and issues are welcome! - -You may notice there are two sets of tests running, on two different services: - -* Travis CI runs the [PHPUnit](https://phpunit.de/) test suite in a variety of environment configurations (e.g. Redis enabled vs. Redis disabled). -* Circle CI runs the [Behat](http://behat.org/) test suite against a Pantheon site, to ensure the plugin's compatibility with the Pantheon platform. - -Both of these test suites can be run locally, with a varying amount of setup. - -PHPUnit requires the [WordPress PHPUnit test suite](https://make.wordpress.org/core/handbook/testing/automated-testing/phpunit/), and access to a database with name `wordpress_test`. If you haven't already configured the test suite locally, you can run `bash bin/install-wp-tests.sh wordpress_test root '' localhost`. You'll also need to enable Redis and the PHPRedis extension in order to run the test suite against Redis. - -Behat requires a Pantheon site with Redis enabled. Once you've created the site, you'll need [install Terminus](https://github.com/pantheon-systems/terminus#installation), and set the `TERMINUS_TOKEN`, `TERMINUS_SITE`, and `TERMINUS_ENV` environment variables. Then, you can run `./bin/behat-prepare.sh` to prepare the site for the test suite. +See [CONTRIBUTING.md](https://github.com/pantheon-systems/wp-redis/blob/master/CONTRIBUTING.md) for information on contributing. == Frequently Asked Questions == @@ -117,6 +102,9 @@ There's a known issue with WordPress `alloptions` cache design. Specifically, a == Changelog == += 1.3.0 (November 29th, 2022) = +* Added CONTRIBUTING.MD and GitHub action to automate deployments to wp.org. [[#368](https://github.com/pantheon-systems/wp-redis/pull/368)] + = 1.2.0 (February 17, 2022) = * Adds support for Relay via `WP_REDIS_USE_RELAY` constant [[#344](https://github.com/pantheon-systems/wp-redis/pull/344)]. diff --git a/wp-redis.php b/wp-redis.php index 5da9639..c374f71 100644 --- a/wp-redis.php +++ b/wp-redis.php @@ -3,7 +3,7 @@ * Plugin Name: WP Redis * Plugin URI: http://github.com/pantheon-systems/wp-redis/ * Description: WordPress Object Cache using Redis. Requires the PhpRedis extension (https://github.com/phpredis/phpredis). - * Version: 1.2.0 + * Version: 1.3.0 * Author: Pantheon, Josh Koenig, Matthew Boynes, Daniel Bachhuber, Alley Interactive * Author URI: https://pantheon.io/ */