[Bug 4543] New: Please disable missing terminfo warnings (at least give an option to)

mercurial-bugs at selenic.com mercurial-bugs at selenic.com
Wed Feb 18 11:05:04 UTC 2015


http://bz.selenic.com/show_bug.cgi?id=4543

          Priority: normal
            Bug ID: 4543
                CC: mercurial-devel at selenic.com
          Assignee: bugzilla at selenic.com
           Summary: Please disable missing terminfo warnings (at least
                    give an option to)
          Severity: bug
    Classification: Unclassified
                OS: Linux
          Reporter: Marcin.Kasperski at mekk.waw.pl
          Hardware: PC
            Status: UNCONFIRMED
           Version: unspecified
         Component: color
           Product: Mercurial

Background/context
=====================

I started using (slightly patched) "hg wip" from
http://jordi.inversethought.com/blog/customising-mercurial-like-a-pro/ and
therefore enabled terminfo.

Everything works great on true terminal, but whenever I spawn some command
(even not related to colors in any way, say "M-! hg status" or "M-! hg push")
from emacs, I get the following warnings on my output

   no terminfo entry for setab/setaf: reverting to ECMA-48 color
   warning: failed to set color mode to terminfo

Apart from that commands work properly, in fact even "M-! hg wip" shows up
properly (simply is not colorized).

The warnings are correct per se ("dumb" terminal provided by emacs in those
cases is, well, dumb), but completely useless for me and spoil useful output
without providing any value.

Please, let me get rid of those warnings somehow without sacrificing
terminfo...

Suggestions
===================

Any of those would do, in my order of preference:

a) Just downgrade all color warnings to debug (as some already are). It is easy
to notify that there are no colors, no need to mention it.

b) Disable those warnings specifically for TERM=dumb (emacs is rather popular,
after all).

c) Handle

  [color]
  no_warnings=true

  or sth similar

Side problems
==================

Shouldn't color initialize later (once it is really neeeded)? I have no color
rules for push, pull, status or id, still those commands also fire the warning.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Mercurial-devel mailing list