Skip to content

Commit

Permalink
Merge c1bb2b0 into 27c4c90
Browse files Browse the repository at this point in the history
  • Loading branch information
ericmann committed Dec 29, 2018
2 parents 27c4c90 + c1bb2b0 commit b6b17df
Show file tree
Hide file tree
Showing 19 changed files with 3,449 additions and 288 deletions.
21 changes: 21 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# This file is for unifying the coding style for different editors and IDEs
# editorconfig.org

# WordPress Coding Standards
# https://make.wordpress.org/core/handbook/coding-standards/

root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = tab

[{*.json,*.yml}]
indent_style = space
indent_size = 2

[{*.txt,wp-config-sample.php}]
end_of_line = crlf
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
.idea/
vendor
.idea
vendor
build
24 changes: 24 additions & 0 deletions .phpcs.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?xml version="1.0"?>
<ruleset name="PSR-1 and PSR-2 code sniffs">
<description>Generally-applicable sniffs for modern PHP development</description>

<rule ref="PSR1">
<exclude name="PSR1.Files.SideEffects.FoundWithSymbols" />
</rule>
<rule ref="PSR2">
<exclude name="PSR2.Classes.PropertyDeclaration.Underscore" />
</rule>


<!-- Check all PHP files in directory tree by default. -->
<arg name="extensions" value="php"/>
<file>.</file>

<!-- Show progress and sniff codes in all reports -->
<arg value="ps"/>

<exclude-pattern>*/vendor/*</exclude-pattern>
<exclude-pattern>*/tests/*</exclude-pattern>
<exclude-pattern>*/languages/*</exclude-pattern>
<exclude-pattern>*/deprecatded.php</exclude-pattern>
</ruleset>
26 changes: 26 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
language: php

matrix:
include:
- php: 7.3
- php: 7.2
- php: 7.1
- php: 7.3
env: TRAVISCI=phpcs
allow_failures:
- php: 7.3
env: TRAVISCI=phpcs

install:
- composer install --dev --no-interaction

script:
- mkdir -p build/logs
- php vendor/bin/phpunit -c phpunit.xml.dist
- |
if [[ "$TRAVISCI" == "phpcs" ]] ; then
php vendor/bin/phpcs
fi
after_success:
- travis_retry php vendor/bin/php-coveralls
34 changes: 24 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
WP Session Manager
==================
# WP Session Manager [![Build Status][travis-image]][travis-url] [![Coverage Status][coveralls-image]][coveralls-url]

Session management for WordPress.

Expand Down Expand Up @@ -57,6 +56,13 @@ None
Changelog
---------

**4.0.0**
- New: Add an object cache based handler to leverage Redis or Memcached if available for faster queries.
- Update: Bump minimum PHP requirements due to out-of-date version deprecations.
- Fix: Correct a race condition where a session was created before the database table existed.
- Fix: Correct a race condition where the `$wpdb` global is not yet set when a session is deleted from the database.
- Fix: Remove unnecessary integer session ID from the stored data table.

**3.0.4**
- Update: Add support for the `wp_install` hook to create custom table immediately.

Expand Down Expand Up @@ -131,6 +137,9 @@ Changelog
Upgrade Notice
--------------

**4.0**
This version requires PHP 7.1 or higher.

**3.0**
This version requires PHP 5.6 or higher and uses Composer-powered autoloading to incorporate Sessionz for transparent session management.

Expand All @@ -145,12 +154,17 @@ First version
Additional Information
----------------------

**Contributors:** ericmann
**Donate link:** https://paypal.me/eam
**Tags:** session
**Requires at least:** 4.7
**Tested up to:** 4.9.2
**Requires PHP:** 5.6
**Stable tag:** 3.0.4
**License:** GPLv2 or later
**Contributors:** ericmann
**Donate link:** https://paypal.me/eam
**Tags:** session
**Requires at least:** 4.7
**Tested up to:** 5.0.2
**Requires PHP:** 7.1
**Stable tag:** 4.0.0
**License:** GPLv2 or later
**License URI:** http://www.gnu.org/licenses/gpl-2.0.html

[travis-image]: https://travis-ci.org/ericmann/wp-session-manager.svg?branch=master
[travis-url]: https://travis-ci.org/ericmann/wp-session-manager
[coveralls-image]: https://coveralls.io/repos/github/ericmann/wp-session-manager/badge.svg?branch=master
[coveralls-url]: https://coveralls.io/github/ericmann/wp-session-manager?branch=master
14 changes: 8 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name" : "ericmann/wp-session-manager",
"description" : "Prototype session management for WordPress.",
"version" : "3.0.4",
"version" : "4.0.0",
"type" : "wordpress-plugin",
"keywords" : ["session"],
"homepage" : "https://github.com/ericmann/wp-session-manager",
Expand All @@ -15,17 +15,19 @@
"role" : "Developer"
}
],
"require-dev" : {},
"require-dev" : {
"phpunit/phpunit": "^7.5",
"php-coveralls/php-coveralls": "^2.1",
"squizlabs/php_codesniffer": "^3.4"
},
"require" : {
"php": ">=5.6",
"php": ">=7.1",
"ericmann/sessionz": "^0.3"
},
"platform": {
"php": "5.6"
},
"autoload": {
"classmap": [
"includes/SessionHandler.php",
"includes/CacheHandler.php",
"includes/DatabaseHandler.php",
"includes/Option.php",
"includes/OptionsHandler.php"
Expand Down

0 comments on commit b6b17df

Please sign in to comment.