Fix URls and folder naming

Closes woocommerce/woocommerce-beta-tester#6
Closes woocommerce/woocommerce-beta-tester#7
This commit is contained in:
Mike Jolley 2017-06-19 15:28:17 +01:00
parent 9e81908d52
commit cb3dcf5eae
2 changed files with 16 additions and 13 deletions

View File

@ -3,9 +3,9 @@ Author URI: http://woothemes.com/
Plugin URI: https://github.com/woothemes/woocommerce-beta-tester
Contributors: woothemes, mikejolley, claudiosanches
Tags: woocommerce, wc, beta, beta tester, bleeding edge
Requires at least: 4.2
Tested up to: 4.4
Stable Tag: 1.0.2
Requires at least: 4.4
Tested up to: 4.8
Stable Tag: 1.0.3
Run bleeding edge versions of WooCommerce from our Github repo. This will replace your installed version of WooCommerce with the latest tagged release on Github - use with caution, and not on production sites. You have been warned.
@ -21,7 +21,10 @@ Based on WP_GitHub_Updater by Joachim Kudish and code by Patrick Garman.
== Changelog ==
= 1.0.1 =
= 1.0.3 =
* Fix repo URLs and directory renaming.
= 1.0.2 =
* Updated API URL.
= 1.0.1 =

View File

@ -1,13 +1,13 @@
<?php
/**
* Plugin Name: WooCommerce Beta Tester
* Plugin URI: https://github.com/woothemes/woocommerce-beta-tester
* Plugin URI: https://github.com/woocommerce/woocommerce-beta-tester
* Description: Run bleeding edge versions of WooCommerce from our Github repo. This will replace your installed version of WooCommerce with the latest tagged release on Github - use with caution, and not on production sites. You have been warned.
* Version: 1.0.2
* Version: 1.0.3
* Author: Mike Jolley
* Author URI: http://woothemes.com/
* Requires at least: 4.2
* Tested up to: 4.4
* Author URI: http://woocommerce.com/
* Requires at least: 4.4
* Tested up to: 4.8
*
* Based on WP_GitHub_Updater by Joachim Kudish.
*/
@ -61,7 +61,7 @@ elseif ( ! class_exists( 'WC_Beta_Tester' ) ) :
'slug' => 'woocommerce',
'proper_folder_name' => 'woocommerce',
'api_url' => 'https://api.github.com/repos/woocommerce/woocommerce',
'github_url' => 'https://github.com/woothemes/woocommerce',
'github_url' => 'https://github.com/woocommerce/woocommerce',
'requires' => '4.4',
'tested' => '4.4'
);
@ -84,7 +84,7 @@ elseif ( ! class_exists( 'WC_Beta_Tester' ) ) :
$this->config[ 'new_version' ] = $this->get_latest_prerelease();
$this->config[ 'last_updated' ] = $this->get_date();
$this->config[ 'description' ] = $this->get_description();
$this->config[ 'zip_url' ] = 'https://github.com/woothemes/woocommerce/zipball/' . $this->config[ 'new_version' ];
$this->config[ 'zip_url' ] = 'https://github.com/woocommerce/woocommerce/zipball/' . $this->config[ 'new_version' ];
}
/**
@ -278,7 +278,7 @@ elseif ( ! class_exists( 'WC_Beta_Tester' ) ) :
public function upgrader_source_selection( $source, $remote_source, $upgrader ) {
global $wp_filesystem;
if ( strstr( $source, '/woothemes-woocommerce-' ) ) {
if ( strstr( $source, '/woocommerce-woocommerce-' ) ) {
$corrected_source = trailingslashit( $remote_source ) . trailingslashit( $this->config[ 'proper_folder_name' ] );
if ( $wp_filesystem->move( $source, $corrected_source, true ) ) {
@ -306,7 +306,7 @@ if ( ! function_exists( 'wcbt_woocoommerce_not_installed' ) ) {
function wcbt_woocoommerce_not_installed() {
echo '<div class="error"><p>' . sprintf( __( 'WooCommerce Beta Tester requires %s to be installed.', 'woocommerce-beta-tester' ), '<a href="http://www.woothemes.com/woocommerce/" target="_blank">WooCommerce</a>' ) . '</p></div>';
echo '<div class="error"><p>' . sprintf( __( 'WooCommerce Beta Tester requires %s to be installed.', 'woocommerce-beta-tester' ), '<a href="http://www.woocommerce.com/" target="_blank">WooCommerce</a>' ) . '</p></div>';
}