コード例 #1
0
ファイル: environment.py プロジェクト: Shasthojoy/veil
def get_application_version():
    if VEIL_ENV.is_dev or VEIL_ENV.is_test:
        return VEIL_ENV.type
    global _application_version
    from veil.utility.shell import shell_execute
    if not _application_version:
        app_commit_hash = shell_execute('git rev-parse HEAD', cwd=VEIL_HOME, capture=True)
        framework_commit_hash = get_veil_framework_version()
        _application_version = '{}-{}'.format(app_commit_hash, framework_commit_hash)
    return _application_version
コード例 #2
0
def get_application_version():
    if VEIL_ENV.is_dev or VEIL_ENV.is_test:
        return VEIL_ENV.type
    global _application_version
    from veil.utility.shell import shell_execute
    if not _application_version:
        app_commit_hash = shell_execute('git rev-parse HEAD', cwd=VEIL_HOME, capture=True)
        framework_commit_hash = get_veil_framework_version()
        _application_version = '{}-{}'.format(app_commit_hash, framework_commit_hash)
    return _application_version
コード例 #3
0
ファイル: environment.py プロジェクト: JoonyLi/veil
def get_application_version():
    if 'development' == VEIL_SERVER:
        return 'development'
    if 'test' == VEIL_SERVER:
        return 'test'
    global _application_version
    from veil.utility.shell import shell_execute

    if not _application_version:
        app_commit_hash = shell_execute('git rev-parse HEAD', cwd=VEIL_HOME, capture=True).strip()
        framework_commit_hash = get_veil_framework_version()
        _application_version = '{}-{}'.format(app_commit_hash, framework_commit_hash)
    return _application_version
コード例 #4
0
ファイル: environment.py プロジェクト: JoonyLi/veil
def get_veil_framework_version():
    from veil.utility.shell import shell_execute

    return shell_execute('git rev-parse HEAD', cwd=VEIL_FRAMEWORK_HOME, capture=True).strip()
コード例 #5
0
ファイル: environment.py プロジェクト: Shasthojoy/veil
def get_veil_framework_version():
    from veil.utility.shell import shell_execute
    return shell_execute('git rev-parse HEAD', cwd=VEIL_FRAMEWORK_HOME, capture=True)