Exemple #1
0
    def show_version(self):
        from azure.cli.core.util import get_az_version_string, show_updates
        from azure.cli.core.commands.constants import (SURVEY_PROMPT, SURVEY_PROMPT_COLOR,
                                                       UX_SURVEY_PROMPT, UX_SURVEY_PROMPT_COLOR)

        ver_string, updates_available = get_az_version_string()
        print(ver_string)
        show_updates(updates_available)

        show_link = self.config.getboolean('output', 'show_survey_link', True)
        if show_link:
            print('\n' + (SURVEY_PROMPT_COLOR if self.enable_color else SURVEY_PROMPT))
            print(UX_SURVEY_PROMPT_COLOR if self.enable_color else UX_SURVEY_PROMPT)
Exemple #2
0
    def show_version(self):
        from azure.cli.core.util import get_az_version_string, show_updates
        from azure.cli.core.commands.constants import SURVEY_PROMPT_STYLED, UX_SURVEY_PROMPT_STYLED
        from azure.cli.core.style import print_styled_text

        ver_string, updates_available_components = get_az_version_string()
        print(ver_string)
        show_updates(updates_available_components)

        show_link = self.config.getboolean('output', 'show_survey_link', True)
        if show_link:
            print_styled_text()
            print_styled_text(SURVEY_PROMPT_STYLED)
            print_styled_text(UX_SURVEY_PROMPT_STYLED)