Skip to content

Commit e37af63

Browse files
Pods Alternative Cache 2.1.8
1 parent 32af681 commit e37af63

9 files changed

Lines changed: 187 additions & 29 deletions

File tree

.github/workflows/mt-code-review.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
name: Prepare Release Branch
2+
env:
3+
PR_PREFIX: 'Pods Gravity Forms '
4+
PR_LABELS: 'Type: Release'
5+
MILESTONE_PREFIX: 'Pods Gravity Forms '
6+
BRANCH_PREFIX: 'release/'
7+
WPORG_PLUGIN_FILE: 'pods-gravity-forms.php'
8+
WPORG_PLUGIN_VERSION_CONSTANT_NAME: 'PODS_GF_VERSION'
9+
on:
10+
workflow_dispatch:
11+
inputs:
12+
new_plugin_version:
13+
description: 'New plugin version (without the "-a-1"), defaults to the next incremental version from package.json'
14+
required: false
15+
version_increment:
16+
description: 'OR Version increment scheme (if incrementing the package.json version; patch=x.x.x, minor=x.x, major=x.0)'
17+
required: true
18+
type: choice
19+
default: 'patch'
20+
options:
21+
- 'major'
22+
- 'minor'
23+
- 'patch'
24+
jobs:
25+
prepare_release_branch:
26+
runs-on: ubuntu-latest
27+
steps:
28+
- name: Checkout the code
29+
uses: actions/checkout@v4
30+
with:
31+
token: ${{ secrets.GH_BOT_PUSH }}
32+
- name: Maybe use the version number from inputs
33+
if: ${{ github.event.inputs.new_plugin_version != null && github.event.inputs.new_plugin_version != '' }}
34+
shell: bash
35+
run: |
36+
echo "PLUGIN_VERSION=${{ github.event.inputs.new_plugin_version }}" >> $GITHUB_ENV
37+
- name: Maybe lookup the version number from package.json
38+
id: version-lookup
39+
if: ${{ github.event.inputs.new_plugin_version == null || github.event.inputs.new_plugin_version == '' }}
40+
shell: bash
41+
run: |
42+
echo "CURRENT_VERSION=$(jq -r .version package.json)" >> $GITHUB_OUTPUT
43+
- name: Maybe get the next version information
44+
if: ${{ steps.version-lookup.outputs.CURRENT_VERSION != null && steps.version-lookup.outputs.CURRENT_VERSION != '' }}
45+
uses: reecetech/version-increment@2023.10.2
46+
id: version-increment
47+
with:
48+
scheme: semver
49+
increment: ${{ github.event.inputs.version_increment }}
50+
- name: Maybe store the next version
51+
if: ${{ steps.version-increment.outputs.version != null && steps.version-increment.outputs.version != '' }}
52+
shell: bash
53+
run: |
54+
echo "PLUGIN_VERSION=${{ steps.version-increment.outputs.version }}" >> $GITHUB_ENV
55+
- name: What are we doing?
56+
run: |
57+
echo PLUGIN_VERSION: ${{ env.PLUGIN_VERSION }}
58+
- name: Run wporg-replace
59+
uses: sc0ttkclark/wporg-replace@v1.0.7
60+
with:
61+
plugin_version: '${{ env.PLUGIN_VERSION }}-a-1'
62+
plugin_version_constant_name: ${{ env.WPORG_PLUGIN_VERSION_CONSTANT_NAME }}
63+
plugin_file: ${{ env.WPORG_PLUGIN_FILE }}
64+
plugin_path: ${{ github.workspace }}
65+
- name: Create Milestone
66+
id: create-milestone
67+
uses: WyriHaximus/github-action-create-milestone@v1.2.0
68+
continue-on-error: true
69+
with:
70+
title: '${{ env.MILESTONE_PREFIX }}${{ env.PLUGIN_VERSION }}'
71+
env:
72+
GITHUB_TOKEN: ${{ secrets.GH_BOT_PUSH }}
73+
- name: Create Pull Request
74+
id: create-pull-request
75+
uses: peter-evans/create-pull-request@v5.0.2
76+
with:
77+
token: ${{ secrets.GH_BOT_PUSH }}
78+
branch: '${{ env.BRANCH_PREFIX }}${{ env.PLUGIN_VERSION }}'
79+
commit-message: 'Set version to ${{ env.PLUGIN_VERSION }}-a-1'
80+
title: '${{ env.PR_PREFIX }}${{ env.PLUGIN_VERSION }}'
81+
labels: ${{ env.PR_LABELS }}
82+
assignees: ${{ github.actor }}
83+
milestone: ${{ steps.create-milestone.outputs.number }}
84+
draft: true
Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,20 @@
11
name: Deploy to WordPress.org
22
on:
3-
push:
4-
tags:
5-
- "*"
3+
release:
4+
types: [published]
65
jobs:
76
tag:
87
name: New tag
98
runs-on: ubuntu-latest
109
steps:
11-
- uses: actions/checkout@master
10+
- name: Check the version number from package.json
11+
shell: bash
12+
run: echo "PLUGIN_VERSION=$(jq -r .version package.json)" >> $GITHUB_ENV
13+
- name: Checkout the code
14+
uses: actions/checkout@v4
1215
- name: WordPress Plugin Deploy
1316
uses: 10up/action-wordpress-plugin-deploy@master
1417
env:
1518
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }}
1619
SVN_USERNAME: ${{ secrets.SVN_USERNAME }}
20+
VERSION: ${{ env.PLUGIN_VERSION }}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: "WordPress version checker"
2+
on:
3+
push:
4+
branches:
5+
- main
6+
- release/*
7+
schedule:
8+
- cron: '0 0 * * *'
9+
10+
permissions:
11+
issues: write
12+
13+
jobs:
14+
wordpress-version-checker:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: WordPress version checker
18+
uses: skaut/wordpress-version-checker@v1.0.0
19+
with:
20+
repo-token: ${{ secrets.GITHUB_TOKEN }}
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: WordPress.org Update Versions
2+
env:
3+
WPORG_PLUGIN_FILE: 'pods-alternative-cache.php'
4+
WPORG_PLUGIN_VERSION_CONSTANT_NAME: 'PODS_ALT_CACHE_VERSION'
5+
on:
6+
workflow_dispatch:
7+
inputs:
8+
plugin_version:
9+
description: 'Plugin version'
10+
required: false
11+
tested_wp_version:
12+
description: 'Tested up to WP version'
13+
required: false
14+
minimum_wp_version:
15+
description: 'Minimum WP version'
16+
required: false
17+
minimum_php_version:
18+
description: 'Minimum PHP version'
19+
required: false
20+
pull_request:
21+
paths:
22+
- 'package.json'
23+
jobs:
24+
wporg_replace:
25+
runs-on: ubuntu-latest
26+
steps:
27+
- name: What are we doing?
28+
run: |
29+
echo plugin_version: ${{ github.event.inputs.plugin_version }}
30+
echo tested_wp_version: ${{ github.event.inputs.tested_wp_version }}
31+
echo minimum_wp_version: ${{ github.event.inputs.minimum_wp_version }}
32+
echo minimum_php_version: ${{ github.event.inputs.minimum_php_version }}
33+
- name: Checkout the code
34+
uses: actions/checkout@v4
35+
with:
36+
token: ${{ secrets.GH_BOT_PUSH }}
37+
- name: Check the version number from package.json
38+
shell: bash
39+
run: echo "PLUGIN_VERSION=$(jq -r .version package.json)" >> $GITHUB_ENV
40+
- name: Run wporg-replace
41+
uses: sc0ttkclark/wporg-replace@v1.0.7
42+
with:
43+
plugin_version: ${{ (github.event.inputs.plugin_version != '') && github.event.inputs.plugin_version || env.PLUGIN_VERSION }}
44+
plugin_version_constant_name: ${{ env.WPORG_PLUGIN_VERSION_CONSTANT_NAME }}
45+
tested_wp_version: ${{ github.event.inputs.tested_wp_version }}
46+
minimum_wp_version: ${{ github.event.inputs.minimum_wp_version }}
47+
minimum_php_version: ${{ github.event.inputs.minimum_php_version }}
48+
plugin_file: ${{ env.WPORG_PLUGIN_FILE }}
49+
plugin_path: ${{ github.workspace }}
50+
- name: Commit changes
51+
id: auto-commit-action
52+
uses: stefanzweifel/git-auto-commit-action@v4
53+
with:
54+
file_pattern: ${{ env.WPORG_PLUGIN_FILE }} readme.txt package.json
55+
commit_message: Update wporg version(s)
56+
- name: "Run if changes have been detected"
57+
if: steps.auto-commit-action.outputs.changes_detected == 'true'
58+
run: echo "Changes!"
59+
- name: "Run if no changes have been detected"
60+
if: steps.auto-commit-action.outputs.changes_detected == 'false'
61+
run: echo "No Changes!"

classes/Pods/Alternative/Cache/Storage.php

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "pods-alternative-cache",
3-
"version": "2.1.7",
3+
"version": "2.1.8",
44
"description": "Alternative caching engine for Pods for large sites on hosts with hard limits on how much you can store in the object cache.",
55
"author": "Pods Foundation, Inc",
66
"homepage": "https://pods.io",

pods-alternative-cache.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
Plugin Name: Pods Alternative Cache
44
Plugin URI: https://pods.io/2014/04/16/introducing-pods-alternative-cache/
55
Description: Alternative caching engine for Pods for large sites on hosts with hard limits on how much you can store in the object cache
6-
Version: 2.1.7
6+
Version: 2.1.8
77
Author: Pods Framework Team
88
Author URI: https://pods.io/
99
*/
1010

11-
define( 'PODS_ALT_CACHE_VERSION', '2.1.7' );
11+
define( 'PODS_ALT_CACHE_VERSION', '2.1.8' );
1212
define( 'PODS_ALT_CACHE_DIR', plugin_dir_path( __FILE__ ) );
1313

1414
/**

readme.txt

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ Contributors: sc0ttkclark
33
Donate link: https://friends.pods.io/
44
Tags: pods, cache, wpengine
55
Requires at least: 3.8
6-
Tested up to: 6.2
6+
Tested up to: 6.5
77
Requires PHP: 5.6
8-
Stable tag: 2.1.7
8+
Stable tag: 2.1.8
99
License: GPLv2 or later
1010
License URI: http://www.gnu.org/licenses/gpl-2.0.html
1111

@@ -76,6 +76,12 @@ Disable object cache fallback, when File writes fail:
7676

7777
== Changelog ==
7878

79+
= 2.1.8 - March 24th, 2024 =
80+
81+
* Fixed: Resolved a PHP notices with the storage set method. (@sc0ttkclark)
82+
* Fixed: Resolved an issue which was causing the cache group not be utilized properly when setting the fallback value. (@sc0ttkclark)
83+
* Fixed: Tested on WP 6.5 and PHP 7.2+. (@sc0ttkclark)
84+
7985
= 2.1.7 - March 13th, 2023 =
8086

8187
* Fixed: Caught a bug hanging around for a few years that only happened in edge cases -- checking if file/directory still exists before trying to delete/remove it. (@sc0ttkclark)

0 commit comments

Comments
 (0)