Elgg  Version 1.11
version.php
Go to the documentation of this file.
1 <?php
12 // YYYYMMDD = Elgg Date
13 // XX = Interim incrementer
14 $version = 2015041400;
15 
16 $composerJson = file_get_contents(dirname(__FILE__) . "/composer.json");
17 if ($composerJson === false) {
18  throw new Exception("Unable to read composer.json file!");
19 }
20 
21 $composer = json_decode($composerJson);
22 if ($composer === null) {
23  throw new Exception("JSON parse error while reading composer.json!");
24 }
25 
26 // Human-friendly version name
27 if (!isset($composer->version)) {
28  throw new Exception("Version field must be set in composer.json!");
29 }
30 $release = $composer->version;
if($composerJson===false) $composer
Definition: version.php:21
$composerJson
Definition: version.php:16
$version
Definition: version.php:14
if($composer===null) if(!isset($composer->version)) $release
Definition: version.php:30