Skip to content

Commit 5ed4fc8

Browse files
authored
Merge pull request #7 from emrikol/v1.0.1
V1.0.1
2 parents 3a0973f + 38d3190 commit 5ed4fc8

File tree

14 files changed

+2565
-16
lines changed

14 files changed

+2565
-16
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules/

Gruntfile.js

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
module.exports = function( grunt ) {
2+
grunt.initConfig( {
3+
pkg: grunt.file.readJSON( 'package.json' ),
4+
5+
shell: {
6+
target: {
7+
command: 'wp2md convert readme.txt > readme.md'
8+
}
9+
},
10+
11+
version: {
12+
readme: {
13+
options: {
14+
prefix: 'Stable tag:\\s*'
15+
},
16+
src: ['readme.txt']
17+
},
18+
scss: {
19+
options: {
20+
prefix: 'Version:\\s*'
21+
},
22+
src: ['scss/style.scss']
23+
},
24+
package: {
25+
src: ['package.json']
26+
}
27+
},
28+
29+
clean: {
30+
main: ['release/<%= pkg.version %>']
31+
},
32+
33+
copy: {
34+
main: {
35+
src: [
36+
'focus.php',
37+
'LICENSE',
38+
'readme.txt',
39+
'includes/**'
40+
],
41+
dest: 'release/<%= pkg.version %>/'
42+
}
43+
},
44+
45+
compress: {
46+
main: {
47+
options: {
48+
mode: 'zip',
49+
archive: './release/<%= pkg.name %>-v<%= pkg.version %>.zip'
50+
},
51+
expand: true,
52+
cwd: 'release/<%= pkg.version %>/',
53+
src: ['**/*'],
54+
dest: '<%= pkg.name %>/'
55+
}
56+
},
57+
58+
replace: {
59+
readme: {
60+
src: ['release/<%= pkg.version %>/readme.txt'],
61+
overwrite: true, // overwrite matched source files
62+
replacements: [{
63+
from: "[![Build Status](https://travis-ci.org/emrikol/focus.svg?branch=master)](https://travis-ci.org/emrikol/focus)\n\n",
64+
to: ''
65+
}]
66+
}
67+
},
68+
69+
// Bump plugin: grunt version:plugin:patch; grunt version:readme:patch
70+
// Bump dropin: grunt version:dropin:patch
71+
// Bump everything: grunt version::patch
72+
73+
version: {
74+
readme: {
75+
options: {
76+
prefix: 'Stable tag:\\s*'
77+
},
78+
src: ['readme.txt']
79+
},
80+
plugin: {
81+
options: {
82+
prefix: 'Version:\\s*'
83+
},
84+
src: [ 'focus.php', 'includes/admin-page.php' ]
85+
},
86+
dropin: {
87+
options: {
88+
prefix: 'Version:\\s*'
89+
},
90+
src: [ 'includes/object-cache.php' ]
91+
},
92+
package: {
93+
src: ['package.json']
94+
}
95+
},
96+
97+
} );
98+
99+
require( 'load-grunt-tasks' )( grunt );
100+
101+
grunt.registerTask( 'readme', [ 'shell' ] );
102+
grunt.registerTask( 'release', [ 'clean', 'copy', 'replace', 'compress' ] );
103+
104+
grunt.util.linefeed = '\n';
105+
};

focus.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,15 @@
22
/**
33
* Plugin Name: FOCUS Object Cache
44
* Plugin URI: http://wordpress.org/plugins/focus-object-cache/
5-
* Description: A File-based Object Cache that is Utterly Slow. Persistenly caches WP_Cache objects in the file system. Can really help speed up a site that has fast disk access and slow database access.
6-
* Version: 1.0.0
5+
* Description: File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system.
6+
* Version: 1.0.1
77
* Text Domain: focus-cache
88
* Author: Derrick Tennant
99
* Author URI: https://emrikol.com/
1010
* GitHub Plugin URI: https://github.com/emrikol/focus/
1111
* License: GPLv3
1212
* License URI: http://www.gnu.org/licenses/gpl-3.0.html
13+
* Network: true
1314
*
1415
* @package WordPress
1516
*/

includes/admin-page.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<?php
22
/**
3-
* Plugin Name: FOCUS Object Cache
3+
* Name: FOCUS Object Cache
44
* Plugin URI: http://wordpress.org/plugins/focus-object-cache/
5-
* Description: File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system
6-
* Version: 1.0.0
5+
* Description: File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system.
6+
* Version: 1.0.1
77
* Text Domain: focus-cache
88
* Author: Derrick Tennant
99
* Author URI: https://emrikol.com/

includes/object-cache.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?php
22
/**
3-
* Plugin Name: FOCUS Object Cache
3+
* Name: FOCUS Object Cache
44
* Plugin URI: http://wordpress.org/plugins/focus-object-cache/
5-
* Description: File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system
5+
* Description: File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system.
66
* Version: 1.0.0
77
* Text Domain: focus-cache
88
* Author: Derrick Tennant

package.json

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"name": "focus-object-cache",
3+
"title": "FOCUS Object Cache",
4+
"description": "File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system.",
5+
"version": "1.0.1",
6+
"homepage": "https://github.com/emrikol/focus",
7+
"repository": {
8+
"type": "git",
9+
"url": "https://github.com/emrikol/focus"
10+
},
11+
"author": {
12+
"name": "Derrick Tennant",
13+
"email": "emrikol@gmail.com",
14+
"url": "https://emrikol.com"
15+
},
16+
"devDependencies": {
17+
"grunt": "^1.0.1",
18+
"grunt-contrib-clean": "^1.1.0",
19+
"grunt-contrib-compress": "^1.4.3",
20+
"grunt-contrib-copy": "^1.0.0",
21+
"grunt-shell": "^2.1.0",
22+
"grunt-text-replace": "^0.4.0",
23+
"grunt-version": "^1.1.1",
24+
"load-grunt-tasks": "^3.5.2"
25+
},
26+
"license": "GPL-3.0"
27+
}

readme.md

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
# FOCUS Cache
2-
**Donate link:** http://wordpressfoundation.org/donate/
32
**Contributors:** emrikol
3+
**Donate link:** http://wordpressfoundation.org/donate/
44
**Tags:** cache, caching
55
**Requires at least:** 4.3.11
66
**Tested up to:** 4.8
7-
**Stable tag:** 1.0.0
7+
**Stable tag:** 1.0.1
88
**License:** GPLv2 or later
99
**License URI:** http://www.gnu.org/licenses/gpl-2.0.html
1010

11-
File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system
11+
File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system.
1212

1313

1414
## Description
15+
1516
[![Build Status](https://travis-ci.org/emrikol/focus.svg?branch=master)](https://travis-ci.org/emrikol/focus)
1617

1718
I needed a persistent object cache while doing work on a budget hosting provider. A lot of the other file-based caching plugins were either bundled with other things I didn't need (W3 Total Cache), or were old and broken.
@@ -23,10 +24,27 @@ I've been heavily influenced by [redis-cache](https://wordpress.org/plugins/redi
2324

2425
## Installation
2526

26-
Install `object-cache.php` to `wp-content/object-cache.php` with a symlink, by copying the file, or via the settings page in the Tools menu.
27+
Install like any other plugin, directly from your plugins page or manually by copying the files to the `plugins/` folder. Go to the plugin settings page at Settings->FOCUS Cache and click `Enable Object Cache`.
28+
2729

2830
## Changelog
2931

32+
33+
### 1.0.1
34+
35+
* Bugfix: Plugin was unable to be activated in the "Add Plugins" page. This was due to the fact that WordPress detected the wrong PHP file as the plugin and tried to activate it. Renaming the "Plugin Name" header from the PHP files in the `includes/` directory resolved the issue. Thanks to @ramonjosegn on the WordPress.org Support Forums for bringing this to my attention.
36+
* Bugfix: The plugin is now required to be activated across all sites in a multisite installation.
37+
* Readme updates.
38+
39+
3040
### 1.0.0
3141

32-
First Version
42+
First Version
43+
44+
45+
## Upgrade Notice
46+
47+
48+
### 1.0.1
49+
50+
The plugin can now be properly activated via the "Add Plugins" screen.

readme.txt

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,14 @@ Donate link: http://wordpressfoundation.org/donate/
44
Tags: cache, caching
55
Requires at least: 4.3.11
66
Tested up to: 4.8
7-
Stable tag: 1.0.0
7+
Stable tag: 1.0.1
88
License: GPLv2 or later
99
License URI: http://www.gnu.org/licenses/gpl-2.0.html
1010

11-
File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system
11+
File-based Object Cache is Utterly Slow: An Object Caching Dropin for WordPress that uses the local file system.
1212

1313
== Description ==
14+
1415
[![Build Status](https://travis-ci.org/emrikol/focus.svg?branch=master)](https://travis-ci.org/emrikol/focus)
1516

1617
I needed a persistent object cache while doing work on a budget hosting provider. A lot of the other file-based caching plugins were either bundled with other things I didn't need (W3 Total Cache), or were old and broken.
@@ -21,10 +22,22 @@ I've been heavily influenced by [redis-cache](https://wordpress.org/plugins/redi
2122

2223
== Installation ==
2324

24-
Install `object-cache.php` to `wp-content/object-cache.php` with a symlink, by copying the file, or via the settings page in the Tools menu.
25+
Install like any other plugin, directly from your plugins page or manually by copying the files to the `plugins/` folder. Go to the plugin settings page at Settings->FOCUS Cache and click `Enable Object Cache`.
2526

2627
== Changelog ==
2728

29+
= 1.0.1 =
30+
31+
* Bugfix: Plugin was unable to be activated in the "Add Plugins" page. This was due to the fact that WordPress detected the wrong PHP file as the plugin and tried to activate it. Renaming the "Plugin Name" header from the PHP files in the `includes/` directory resolved the issue. Thanks to @ramonjosegn on the WordPress.org Support Forums for bringing this to my attention.
32+
* Bugfix: The plugin is now required to be activated across all sites in a multisite installation.
33+
* Readme updates.
34+
2835
= 1.0.0 =
2936

30-
First Version
37+
First Version
38+
39+
== Upgrade Notice ==
40+
41+
= 1.0.1 =
42+
43+
The plugin can now be properly activated via the "Add Plugins" screen.

0 commit comments

Comments
 (0)