hg color는 hg status/qseries/diff 출력에 한해 콘솔에서 색을 입혀 출력시킬 수 있게 해주는 extension.

Mercurial과 함께 배포되는 기본 extension임.



hgrc 파일에 아래처럼 입력하면 바로 설정됨.

[extensions]

color = 



color 모드 지정은 아래처럼.

[color]

# 유효한 모드는 win32, ansi, auto, off

mode = win32






아래 이미지는 color extension 지정 전후의 출력 비교모습.








각 명령어의 결과에 따른 출력모양새는 다음처럼 지정가능.

# status 결과 포맷

[color]

status.modified = blue bold underline red_background

status.added = green bold

status.removed = red bold blue_background

status.deleted = cyan bold underline

status.unknown = magenta bold underline

status.ignored = black bold


# none 으로 지정하면 해당 항목에 지정된 모든 효과를 날려버림

status.clean = none

status.copied = none


# qseries

qseries.applied = blue bold underline

qseries.unapplied = black bold

qseries.missing = red bold


# diff

diff.diffline = bold

diff.extended = cyan bold

diff.file_a = red bold

diff.file_b = green bold

diff.hunk = magenta

diff.deleted = red

diff.inserted = green

diff.changed = white

diff.trailingwhitespace = bold red_background


# resolve

resolve.unresolved = red bold

resolve.resolved = green bold


# bookmark

bookmarks.current = green


# branches

branches.active = none

branches.closed = black bold

branches.current = green

branches.inactive = none


# tags

tags.normal = green

tags.local = black bold






[참조]

http://mercurial.selenic.com/wiki/ColorExtension













Posted by bloodguy
,