2017 © Pedro Peláez
 

wordpress-muplugin seravo-plugin

Enhances WordPress with Seravo.com specific features and integrations

image

seravo/seravo-plugin

Enhances WordPress with Seravo.com specific features and integrations

  • Wednesday, August 1, 2018
  • by Seravo
  • Repository
  • 9 Watchers
  • 15 Stars
  • 9,928 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 9 Forks
  • 48 Open issues
  • 72 Versions
  • 19 % Grown

The README.md

Seravo.com, (*1)

Seravo Must-use Plugin

Build Status Latest Stable Version Total Downloads Latest Unstable Version License, (*2)

Enhances WordPress with Seravo.com specific features and integrations (also known as WP-palvelu.fi in Finland)., (*3)

Installation

In order to use this with composer you need to add this mu-plugin:, (*4)

https://github.com/roots/bedrock/blob/master/web/app/mu-plugins/bedrock-autoloader.php, (*5)

This is because WordPress won't use mu-plugins from their own folders., (*6)

Then add this to your composer:, (*7)

{
  "require": {
    "seravo/seravo-plugin": "*"
  },
  "extra": {
    "installer-paths": {
      "htdocs/wp-content/mu-plugins/{$name}/": ["type:wordpress-muplugin"]
    }
  }
}

Seravo's customers can simply run wp-seravo-plugin-update to get the latest (tagged) release. For the adventurous, get the git master head with wp-seravo-plugin-update --dev., (*8)

Features

  • Enforces canonical URLs
  • Enforces HTTPS, nags if PHP version is too low, shows a notice is object-cache is not enabled etc
  • Shows notifications from WP-palvelu.fi (@TODO: switch to Seravo.com)
  • Returns 401 (unauthorized) http status code after failed login.
  • Logs all login attempts to /data/log/wp-login.log
  • Hides Update nagging since that is handled by Seravo
  • Uses nocache headers if the site is in development mode
  • Adds Purge Cache -button in adminbar
  • Automatically shows the shadow instance switcher is there are any shadow instances.
  • Allows to list and reset shadow environments
  • Finds and suggests cruft files to remove from a site
  • Shows information about the database, table sizes etc
  • Show information about disk usage, server logs, updates, tests etc
  • And lots, lots more!

Filters

You can insert your own admin notice for users that are in shadow, (*9)

function my_shadow_admin_notice($admin_notice, $current_screen) {
  return '<div class="notice notice-error"><p>This is staging. All content edited here will be lost. Return to production to create or edit content.</p></div>';
}
add_filter( 'seravo_instance_switcher_admin_notice', 'my_shadow_admin_notice', 10, 2 );

Currently the velocity of development is so high that documentation lacks badly behind. To find more filters, just search the source code for apply_filters., (*10)

Development

Using a real site for development

Some of the features in the Seravo Plugin depend on the API that is available only on a real production site, and thus cannot be tested inside a Vagrant box or the like., (*11)

In order to have the git repository on your own computer and in your own editor, while still being able to see the code running on a test site (in the production environment) you can use the command below. It will watch all files for changes and automatically rsync them to the remote server:, (*12)

seravo-plugin$ find * | entr rsync -avz -e 'ssh -q -p 12345' * example@example.seravo.com:/data/wordpress/htdocs/wp-content/mu-plugins/seravo-plugin/
sending incremental file list
README.md

sent 2,999 bytes  received 64 bytes  2,042.00 bytes/sec
total size is 370,596  speedup is 120.99

Installing development dependencies

To ease Seravo Plugin development, composer should be used to install development dependencies. Running composer install installs PHPCS, PHPCBF, WordPress PHPCS standards and Rector., (*13)

Updating translations

Remember to update translations of all public facing string by running inside Vagrant:, (*14)

cd /data/wordpress/htdocs/wp-content/mu-plugins/seravo-plugin
wp i18n make-pot . languages/seravo.pot

NOTE! If this fails on PHP Fatal error: Uncaught Error: Maximum function nesting level of '256' reached temporarily remove the overly complex files with rm js/cruft*., (*15)

Translations can be done for instance by using Poedit. On editor open languages/seravo-fi.po and select Update from pot file which will update the po file. After translating compile the po file to seravo-fi.mo mo file., (*16)

Running Rector and PHPCS

If you have Rector and PHPCS installed locally with composer install, simply run composer test. Alternatively run PHPCS inside local Vagrant or Docker image, or on the same remote site used for testing:, (*17)

ssh -q -p 12345 example@example.seravo.com 'cd '/data/wordpress/htdocs/wp-content/mu-plugins/seravo-plugin/ && phpcs
........S.......WWWWWWWWWWEWWEWWWWW.WWEWWWW.W.WWEWWEWEW..... 60 / 68 (88%)
......W.                                                     68 / 68 (100%)

FILE: ...press/htdocs/wp-content/mu-plugins/seravo-plugin/lib/helpers.php
----------------------------------------------------------------------
FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------
 35 | WARNING | Filesystem function dirname() detected with dynamic
    |         | parameter
 35 | WARNING | Line exceeds 100 characters; contains 118 characters
 44 | WARNING | Line exceeds 100 characters; contains 107 characters
----------------------------------------------------------------------
...

Rector and PHPCS errors can be automatically fixed with composer fix. All Rector errors should be resolved before merging to master even if it's not part of CI tests., (*18)

Changelog

See git history and release commit messages., (*19)

The Versions

01/08 2018

dev-dev-leo

dev-dev-leo http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

26/07 2018

dev-master

9999999-dev http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3 GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

09/07 2018

dev-cruft-show-file-size

dev-cruft-show-file-size http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

27/06 2018

dev-feature-cruft-remove-inactive-plugins

dev-feature-cruft-remove-inactive-plugins http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

27/06 2018

dev-feature-shadows-current

dev-feature-shadows-current http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

21/06 2018

1.9.1

1.9.1.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

14/06 2018

1.9.0

1.9.0.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

01/06 2018

dev-feature-shadows

dev-feature-shadows http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

30/05 2018

dev-feature-coding-guidelines

dev-feature-coding-guidelines http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

23/03 2018

1.8.0

1.8.0.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

14/03 2018

dev-nasusa-master

dev-nasusa-master http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

02/03 2018

dev-feature/pwnedpasswords

dev-feature/pwnedpasswords http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

01/03 2018

dev-nasusa-skill

dev-nasusa-skill http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

03/02 2018

dev-feature-travis-phpcs

dev-feature-travis-phpcs http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPL-3.0-or-later

The Requires

 

by Simo Kemppainen

wordpress wp wp-palvelu seravo seravo.com

18/01 2018

dev-feature-find-cruftfiles

dev-feature-find-cruftfiles http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

18/12 2017

dev-feature-notification-email-field

dev-feature-notification-email-field http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

16/12 2017

1.7.0

1.7.0.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

11/10 2017

dev-update-translations

dev-update-translations http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

26/09 2017

1.6.2

1.6.2.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

25/08 2017

1.6.1

1.6.1.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

25/08 2017

dev-fix-optimize-images-on-by-default

dev-fix-optimize-images-on-by-default http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

21/08 2017

1.6.0

1.6.0.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

16/08 2017

dev-fix-55

dev-fix-55 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

15/08 2017

dev-fix-62

dev-fix-62 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

11/08 2017

dev-hide-functionality-in-networks

dev-hide-functionality-in-networks http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

27/06 2017

dev-feature-image-resolution-page

dev-feature-image-resolution-page http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

21/06 2017

dev-feature-search-replace-page

dev-feature-search-replace-page http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

12/06 2017

dev-feature-tests-page

dev-feature-tests-page http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

08/06 2017

dev-fix-instance-switcher-js-500-error

dev-fix-instance-switcher-js-500-error http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

08/06 2017

dev-feature-log-notifications

dev-feature-log-notifications http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

05/06 2017

dev-fix-undefined-menuclass

dev-fix-undefined-menuclass http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

01/06 2017

dev-fix-updates-page

dev-fix-updates-page http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

01/06 2017

dev-feature-logs-page

dev-feature-logs-page http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

29/05 2017

1.5.4

1.5.4.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

28/05 2017

1.5.3

1.5.3.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

24/05 2017

dev-fix-login-log-not-found

dev-fix-login-log-not-found http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

23/05 2017

1.5.2

1.5.2.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

22/05 2017

1.5.1

1.5.1.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

19/05 2017

1.5.0

1.5.0.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

19/05 2017

dev-feature-check-https

dev-feature-check-https http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

16/05 2017

dev-fix-report-page

dev-fix-report-page http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

16/05 2017

dev-fix-reports-page-style

dev-fix-reports-page-style http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

07/05 2017

dev-update_instance_switching_feature

dev-update_instance_switching_feature http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

05/05 2017

dev-add_nonce_to_update_page_form

dev-add_nonce_to_update_page_form http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

28/04 2017

dev-feature-api-v1

dev-feature-api-v1 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

28/03 2017

dev-feature-backup-management

dev-feature-backup-management http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

24/03 2017

1.4.1

1.4.1.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

17/02 2017

dev-feature-update-checker

dev-feature-update-checker http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

10/02 2017

dev-seravo-plugin-rename

dev-seravo-plugin-rename http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

10/02 2017

1.4.0

1.4.0.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

10/02 2017

1.3.8

1.3.8.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

11/12 2016

dev-feature-domain-management

dev-feature-domain-management http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

30/11 2016

1.3.7

1.3.7.0 http://seravo.com

Enhances WordPress with Seravo.com specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

30/11 2016

dev-feature-stats-disk-health-dns-email

dev-feature-stats-disk-health-dns-email http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

GPLv3

The Requires

 

wordpress wp wp-palvelu seravo seravo.com

11/11 2016

1.3.6

1.3.6.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

02/11 2016

dev-feature-stats-pages

dev-feature-stats-pages http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

27/05 2016

dev-feature-noindex-domain-alias

dev-feature-noindex-domain-alias http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

26/01 2016

1.3.5

1.3.5.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

24/12 2015

1.3.4

1.3.4.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

06/11 2015

1.3.3

1.3.3.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

20/10 2015

1.3.2

1.3.2.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

07/10 2015

dev-feature-vagrant-load-missing-pictures-from-prod

dev-feature-vagrant-load-missing-pictures-from-prod http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

07/10 2015

1.3.1

1.3.1.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

05/10 2015

1.3

1.3.0.0 http://seravo.fi

Enhances WordPress with WP-Palvelu.fi specific features and integrations

  Sources   Download

MIT

The Requires

 

wordpress wp wp-palvelu

30/09 2015

dev-feature-add-wpdb-injector

dev-feature-add-wpdb-injector http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

21/09 2015

1.2

1.2.0.0 http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

06/08 2015

1.1

1.1.0.0 http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

05/08 2015

1.0.4

1.0.4.0 http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

22/05 2015

1.0.3

1.0.3.0 http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

06/05 2015

1.0.2

1.0.2.0 http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

20/04 2015

1.0.1

1.0.1.0 http://seravo.fi

Wordpress Mu-Plugin for wordpress instances in wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu

06/03 2015

1.0

1.0.0.0 http://seravo.fi

Wordpress Mu-Plugin containing features for wordpress instances of wp-palvelu.

  Sources   Download

MIT

wordpress wp wp-palvelu