Hello community, here is the log from the commit of package crmsh for openSUSE:Factory checked in at 2018-05-18 14:28:19 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/crmsh (Old) and /work/SRC/openSUSE:Factory/.crmsh.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "crmsh" Fri May 18 14:28:19 2018 rev:146 rq:610226 version:4.0.0+git.1526547258.54aafa1d Changes: -------- --- /work/SRC/openSUSE:Factory/crmsh/crmsh.changes 2018-04-16 15:45:52.376883540 +0200 +++ /work/SRC/openSUSE:Factory/.crmsh.new/crmsh.changes 2018-05-18 14:28:30.365042684 +0200 @@ -1,0 +2,10 @@ +Fri May 18 07:20:31 UTC 2018 - [email protected] + +- Update to version 4.0.0+git.1526547258.54aafa1d: + * high: bash_completion: Adjust for non-interactive mode(bsc#1090304) + * high: utils: Parse /32 route entries + * low: terminal will lose cursor after type ctrl+c(bsc#1090626) + * low: ui_configure: Adjust prompt string after help messages(bsc#1090140) + * low: bootstrap: Strip spaces before some status descriptions + +------------------------------------------------------------------- Old: ---- crmsh-4.0.0+git.1523871649.78999e05.tar.bz2 New: ---- crmsh-4.0.0+git.1526547258.54aafa1d.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ crmsh.spec ++++++ --- /var/tmp/diff_new_pack.lYRyob/_old 2018-05-18 14:28:30.829025657 +0200 +++ /var/tmp/diff_new_pack.lYRyob/_new 2018-05-18 14:28:30.833025510 +0200 @@ -36,7 +36,7 @@ Summary: High Availability cluster command-line interface License: GPL-2.0-or-later Group: %{pkg_group} -Version: 4.0.0+git.1523871649.78999e05 +Version: 4.0.0+git.1526547258.54aafa1d Release: 0 Url: http://crmsh.github.io Source0: %{name}-%{version}.tar.bz2 ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.lYRyob/_old 2018-05-18 14:28:30.865024336 +0200 +++ /var/tmp/diff_new_pack.lYRyob/_new 2018-05-18 14:28:30.865024336 +0200 @@ -1,4 +1,4 @@ <servicedata> <service name="tar_scm"> <param name="url">git://github.com/ClusterLabs/crmsh.git</param> - <param name="changesrevision">716caabb87275117d3f2b8c550331b86b7235f0d</param></service></servicedata> \ No newline at end of file + <param name="changesrevision">ce8241d2ea413dd5a95eec87f57381ee25077f1c</param></service></servicedata> \ No newline at end of file ++++++ crmsh-4.0.0+git.1523871649.78999e05.tar.bz2 -> crmsh-4.0.0+git.1526547258.54aafa1d.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crmsh-4.0.0+git.1523871649.78999e05/contrib/bash_completion.sh new/crmsh-4.0.0+git.1526547258.54aafa1d/contrib/bash_completion.sh --- old/crmsh-4.0.0+git.1523871649.78999e05/contrib/bash_completion.sh 2018-04-16 11:40:49.000000000 +0200 +++ new/crmsh-4.0.0+git.1526547258.54aafa1d/contrib/bash_completion.sh 2018-05-17 10:54:18.000000000 +0200 @@ -148,7 +148,15 @@ local i=0 for x in $1; do if [[ "$x" == "$3"* ]]; then + if [[ "$x" =~ .*(=|:)$ ]];then + if [[ "$x" =~ ^id=$ ]];then + : + else + COMPREPLY[i++]="$2$x" + fi + else COMPREPLY[i++]="$2$x$4" + fi fi done } @@ -209,7 +217,7 @@ *:*) : great ;; *) pfx="${cur_%%:*}:" ;; esac - cur_="${cur_#*:}" + cur_="${cur_##*:}" ;; esac diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/bootstrap.py new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/bootstrap.py --- old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/bootstrap.py 2018-04-16 11:40:49.000000000 +0200 +++ new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/bootstrap.py 2018-05-17 10:54:18.000000000 +0200 @@ -589,9 +589,9 @@ # only try to start hawk if hawk is installed if service_is_available("hawk.service"): start_service("hawk.service") - status(" Hawk cluster interface is now running. To see cluster status, open:") - status(" https://%s:7630/" % (_context.ip_address)) - status(" Log in with username 'hacluster'%s" % (pass_msg)) + status("Hawk cluster interface is now running. To see cluster status, open:") + status(" https://%s:7630/" % (_context.ip_address)) + status("Log in with username 'hacluster'%s" % (pass_msg)) else: warn("Hawk not installed - not configuring web management interface.") diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/constants.py new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/constants.py --- old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/constants.py 2018-04-16 11:40:49.000000000 +0200 +++ new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/constants.py 2018-05-17 10:54:18.000000000 +0200 @@ -322,6 +322,7 @@ }, } +need_reset = False prompt = '' tmp_cib = False tmp_cib_prompt = "@tmp@" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/ui_configure.py new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/ui_configure.py --- old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/ui_configure.py 2018-04-16 11:40:49.000000000 +0200 +++ new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/ui_configure.py 2018-05-17 10:54:18.000000000 +0200 @@ -195,7 +195,7 @@ lasttopic = '' @classmethod - def help(cls, topic, helptxt): + def help(cls, topic, helptxt, args): if cls.lasttopic == topic and \ time.time() - cls.laststamp < cls.timeout: return @@ -203,11 +203,14 @@ import readline cmdline = readline.get_line_buffer() print("\n%s" % helptxt, end='') - if clidisplay.colors_enabled(): - print("\n%s%s" % (term.render(clidisplay.prompt_noreadline(constants.prompt)), - cmdline), end=' ') + if cmdline.split()[0] != args[0]: + prompt = ' > ' else: - print("\n%s%s" % (constants.prompt, cmdline), end=' ') + if clidisplay.colors_enabled(): + prompt = term.render(clidisplay.prompt_noreadline(constants.prompt)) + else: + prompt = constants.prompt + print("\n%s%s" % (prompt, cmdline), end=' ') cls.laststamp = time.time() cls.lasttopic = topic @@ -219,7 +222,7 @@ if completing.endswith('='): if len(completing) > 1 and options.interactive: topic = completing[:-1] - CompletionHelp.help(topic, agent.meta_parameter(topic)) + CompletionHelp.help(topic, agent.meta_parameter(topic), args) return [] elif '=' in completing: return [] @@ -451,7 +454,7 @@ if completing.endswith('='): if len(completing) > 1 and options.interactive: topic = completing[:-1] - CompletionHelp.help(topic, container_helptxt(args, constants.container_helptxt, topic)) + CompletionHelp.help(topic, container_helptxt(args, constants.container_helptxt, topic), args) return [] container_options = utils.filter_keys(constants.container_helptxt[container_type].keys(), args) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/ui_context.py new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/ui_context.py --- old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/ui_context.py 2018-04-16 11:40:49.000000000 +0200 +++ new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/ui_context.py 2018-05-17 10:54:18.000000000 +0200 @@ -9,6 +9,7 @@ from .msg import common_err, common_info, common_warn from . import ui_utils from . import userdir +from . import constants # import logging @@ -338,10 +339,10 @@ ''' ok = self.current_level().end_game() if options.interactive and not options.batch: - if self.command_name != "help": - print("bye") - else: + if constants.need_reset: utils.ext_cmd("reset") + else: + print("bye") if ok is False and rc == 0: rc = 1 sys.exit(rc) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/utils.py new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/utils.py --- old/crmsh-4.0.0+git.1523871649.78999e05/crmsh/utils.py 2018-04-16 11:40:49.000000000 +0200 +++ new/crmsh-4.0.0+git.1526547258.54aafa1d/crmsh/utils.py 2018-05-17 10:54:18.000000000 +0200 @@ -108,10 +108,13 @@ sp = l.split() if info[0] is None and len(sp) >= 5 and sp[0] == 'default' and sp[1] == 'via': info[0] = sp[4] - if info[0] is not None: - if sp[0].find('/') >= 0 and valfor(sp, 'dev') == info[0]: + if info[0] is not None and valfor(sp, 'dev') == info[0] and sp[0] != 'default': + if sp[0].find('/') >= 0: nw, length = sp[0].split('/') info[1], info[2], info[3] = valfor(sp, 'src'), nw, length + # we are reading /32 route entry + else: + info[1], info[2], info[3] = valfor(sp, 'src'), sp[0], 32 if info[0] is None: raise ValueError("Failed to determine default network interface") return tuple(info) @@ -1152,6 +1155,7 @@ 'Page string rendered for TERM.' if not s: return + constants.need_reset = True w, h = get_winsize() if not need_pager(s, w, h): print(term_render(s)) @@ -1159,6 +1163,7 @@ print(term_render(s)) else: pipe_string(get_pager_cmd(), term_render(s).encode('utf-8')) + constants.need_reset = False def page_gen(g):
