# HG changeset patch # User Marcin Kuzminski # Date 2016-11-14 23:16:24 # Node ID fd4fbbf2a0d085424a1dfb71aed6aa6e02927d1b # Parent ff9a513b30282fdc1a531322934c754d266621f2 system-info: add edition type into app info. diff --git a/rhodecode/controllers/admin/settings.py b/rhodecode/controllers/admin/settings.py --- a/rhodecode/controllers/admin/settings.py +++ b/rhodecode/controllers/admin/settings.py @@ -577,7 +577,7 @@ class SettingsController(BaseController) ), ''), # RhodeCode specific - (_('RhodeCode Version'), c.rhodecode_version, ''), + (_('RhodeCode Version'), val('rhodecode_app')['text'], state('rhodecode_app')), (_('RhodeCode Server IP'), val('server')['server_ip'], state('server')), (_('RhodeCode Server ID'), val('server')['server_id'], state('server')), (_('RhodeCode Configuration'), val('rhodecode_config')['path'], state('rhodecode_config')), diff --git a/rhodecode/lib/system_info.py b/rhodecode/lib/system_info.py --- a/rhodecode/lib/system_info.py +++ b/rhodecode/lib/system_info.py @@ -466,11 +466,18 @@ def vcs_server(): def rhodecode_app_info(): import rhodecode + edition = rhodecode.CONFIG.get('rhodecode.edition') + value = dict( rhodecode_version=rhodecode.__version__, - rhodecode_lib_path=os.path.abspath(rhodecode.__file__) + rhodecode_lib_path=os.path.abspath(rhodecode.__file__), + text='' ) - return SysInfoRes(value=value) + human_value = value.copy() + human_value['text'] = 'RhodeCode {edition}, version {ver}'.format( + edition=edition, ver=value['rhodecode_version'] + ) + return SysInfoRes(value=value, human_value=human_value) def rhodecode_config():