diff --git a/lib/private/updater.php b/lib/private/updater.php index 9827d8a8c12d7084e5f9eab3e10a63c560a0184c..a1b07c5a2428788ec918cc60ee9ae56ed95e605e 100644 --- a/lib/private/updater.php +++ b/lib/private/updater.php @@ -58,6 +58,7 @@ class Updater extends BasicEmitter { $version['updated'] = \OC_Appconfig::getValue('core', 'lastupdatedat'); $version['updatechannel'] = \OC_Util::getChannel(); $version['edition'] = \OC_Util::getEditionString(); + $version['build'] = \OC_Util::getBuild(); $versionString = implode('x', $version); //fetch xml data from updater diff --git a/lib/private/util.php b/lib/private/util.php index 426c5a025f3170f42cf6636829c223d7c0c6ef13..b5c5546da35b320833a1a63f935d07f75c98e670 100755 --- a/lib/private/util.php +++ b/lib/private/util.php @@ -1111,4 +1111,17 @@ class OC_Util { $t = explode('/', $file); return array_pop($t); } + + /** + * A human readable string is generated based on version, channel and build number + * @return string + */ + public static function getHumanVersion() { + $version = OC_Util::getVersionString().' ('.OC_Util::getChannel().')'; + $build = OC_Util::getBuild(); + if(!empty($build) and OC_Util::getChannel() === 'daily') { + $version .= ' Build:' . $build; + } + return $version; + } } diff --git a/settings/templates/admin.php b/settings/templates/admin.php index f655a14be87d04424bb27b512d5442abf2cc5df9..253a7ff5f509cd2437aa999bf155cb21b7b3cee6 100644 --- a/settings/templates/admin.php +++ b/settings/templates/admin.php @@ -264,7 +264,7 @@ if (!$_['internetconnectionworking']) { <fieldset class="personalblock"> <h2><?php p($l->t('Version'));?></h2> - <strong><?php p($theme->getTitle()); ?></strong> <?php p(OC_Util::getVersionString().' ('.OC_Util::getChannel().')'); ?> + <strong><?php p($theme->getTitle()); ?></strong> <?php p(OC_Util::getHumanVersion()) ?> <?php if (OC_Util::getEditionString() === ''): ?> <p> <?php print_unescaped($l->t('Developed by the <a href="http://ownCloud.org/contact" target="_blank">ownCloud community</a>, the <a href="https://github.com/owncloud" target="_blank">source code</a> is licensed under the <a href="http://www.gnu.org/licenses/agpl-3.0.html" target="_blank"><abbr title="Affero General Public License">AGPL</abbr></a>.')); ?> diff --git a/settings/templates/personal.php b/settings/templates/personal.php index 9d21e18e73cbeb6a25b33b1ae463dd3951ecdc1f..2d8652aed7696e8d74d3eba1c0040af5c2b36422 100644 --- a/settings/templates/personal.php +++ b/settings/templates/personal.php @@ -167,7 +167,7 @@ if($_['passwordChangeSupported']) { <fieldset class="personalblock"> <h2><?php p($l->t('Version'));?></h2> - <strong><?php p($theme->getName()); ?></strong> <?php p(OC_Util::getVersionString().' ('.OC_Util::getChannel().')'); ?><br /> + <strong><?php p($theme->getName()); ?></strong> <?php p(OC_Util::getHumanVersion()) ?><br /> <?php if (OC_Util::getEditionString() === ''): ?> <?php print_unescaped($l->t('Developed by the <a href="http://ownCloud.org/contact" target="_blank">ownCloud community</a>, the <a href="https://github.com/owncloud" target="_blank">source code</a> is licensed under the <a href="http://www.gnu.org/licenses/agpl-3.0.html" target="_blank"><abbr title="Affero General Public License">AGPL</abbr></a>.')); ?> <?php endif; ?>