Skip to content

Commit

Permalink
Add beta download channel and flat JSON-based version updater
Browse files Browse the repository at this point in the history
  • Loading branch information
ginatrapani committed Mar 23, 2012
1 parent 1405712 commit adcf30b
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 0 deletions.
4 changes: 4 additions & 0 deletions version.beta.inc.php
@@ -0,0 +1,4 @@
<?php
//Edit this file on each new release
$current_version = "1.0.4-b2";
$current_version_download_link = "http://thinkupapp.com/downloads/beta/thinkup_1.0.4-b2.zip";
1 change: 1 addition & 0 deletions version.json
@@ -0,0 +1 @@
{"version":"1.0.3", "url":"https://github.com/downloads/ginatrapani/ThinkUp/thinkup_1.0.3.zip"}
1 change: 1 addition & 0 deletions version_beta.json
@@ -0,0 +1 @@
{"version":"1.0.4-beta.1", "url":"http://thinkupapp.com/downloads/beta/thinkup_1.0.4-beta.1.zip"}
14 changes: 14 additions & 0 deletions version_download_beta.php
@@ -0,0 +1,14 @@
<?php
/**
* Return current version and download location in JSON format, with override for web updater tests.
*/
require_once('version.beta.inc.php');
header('Content-type: application/json');

// Test override
if (isset($_GET['version']) && isset($_GET['url'])) {
$current_version = $_GET['version'];
$current_version_download_link = $_GET['url'];
}
?>
{"version":"<?= $current_version ?>", "url":"<?= $current_version_download_link ?>"}

0 comments on commit adcf30b

Please sign in to comment.