2017 © Pedro Peláez
 

library wp-github-theme-updater

A library for WordPress that automatic theme updater with GitHub API.

image

inc2734/wp-github-theme-updater

A library for WordPress that automatic theme updater with GitHub API.

  • Friday, July 27, 2018
  • by inc2734
  • Repository
  • 2 Watchers
  • 9 Stars
  • 1,259 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 1 Forks
  • 2 Open issues
  • 13 Versions
  • 22 % Grown

The README.md

WP GitHub Theme Updater

CI Latest Stable Version License, (*1)

Install

$ composer require inc2734/wp-github-theme-updater

How to use

<?php
$updater = new Inc2734\WP_GitHub_Theme_Updater\Bootstrap(
  get_template(),
  'user-name',
  'repository'
);

Filter hooks

inc2734_github_theme_updater_zip_url_/

Customize downloaded package url., (*2)

add_filter(
  'inc2734_github_theme_updater_zip_url_inc2734/snow-monkey',
  function( $url, $user_name, $repository, $tag_name ) {
    return $url;
  },
  10,
  4
);

inc2734_github_theme_updater_request_url_/

Customize requested api url., (*3)

add_filter(
  'inc2734_github_theme_updater_request_url_inc2734/snow-monkey',
  function( $url, $user_name, $repository ) {
    return $url;
  },
  10,
  3
);

inc2734_github_theme_updater_transient_response_/

Customize transient response, (*4)

add_filter(
  'inc2734_github_theme_updater_transient_response_inc2734/snow-monkey',
  function( $transient_response ) {
    return $transient_response;
  }
);

inc2734_github_theme_updater_repository_content_url_/

Customize contents api url., (*5)

add_filter(
  'inc2734_github_theme_updater_repository_content_url_inc2734/snow-monkey',
  function( $url, $user_name, $repository, $theme_name ) {
    return $url;
  },
  10,
  4
);

inc2734_github_theme_updater_repository_content_headers_/

Customize fields contents_api., (*6)

add_filter(
  'inc2734_github_theme_updater_repository_content_headers_inc2734/snow-monkey',
  function( $headers ) {
    return $headers;
  }
);

inc2734_github_theme_updater_zip_url

Obsolete from v2.0.0, (*7)

Customize downloaded api url., (*8)

add_filter(
  'inc2734_github_theme_updater_zip_url',
  function( $url, $user_name, $repository, $tag_name ) {
    if ( 'inc2734' === $user_name && 'snow-monkey-blocks' === $repository ) {
      return 'https://example.com/my-custom-updater-zip-url';
    }
    return $url;
  },
  10,
  4
);

inc2734_github_theme_updater_request_url

Obsolete from v2.0.0, (*9)

Customize requested api url., (*10)

add_filter(
  'inc2734_github_theme_updater_request_url',
  function( $url, $user_name, $repository ) {
    if ( 'inc2734' === $user_name && 'snow-monkey' === $repository ) {
      return 'https://example.com/my-custom-updater-request-url';
    }
    return $url;
  },
  10,
  3
);

The Versions

04/03 2018

0.2.7

0.2.7.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0-or-later

The Requires

  • php >=5.6

 

The Development Requires

04/03 2018

0.2.6

0.2.6.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

28/11 2017

0.2.5

0.2.5.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

29/10 2017

0.2.4

0.2.4.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

09/10 2017

0.2.3

0.2.3.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

30/09 2017

0.2.2

0.2.2.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

14/09 2017

0.2.1

0.2.1.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

31/08 2017

0.2.0

0.2.0.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

30/08 2017

0.1.2

0.1.2.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

30/08 2017

0.1.1

0.1.1.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

02/07 2017

0.1.0

0.1.0.0

A library for WordPress that automatic theme updater with GitHub API.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires