[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Some basic hg tips to improve usability
From: |
Jordi Gutiérrez Hermoso |
Subject: |
Some basic hg tips to improve usability |
Date: |
Wed, 19 Jun 2013 11:03:41 -0400 |
Now that I'm seeing a batch of GSoC students get acquainted with hg, I
would like to offer a few tips.
Mercurial has a few extensions that really should always be enabled
but in reality aren't due to a number of factors (mostly because they
don't work in all terminal types, particularly not in cmd.exe).
I recommend everyone to add the following to their ~/.hgrc
[extensions]
graphlog=
color=
progress=
pager=
For the colour extension, you might want to modify the default
colours and underlining for "hg status":
[color]
status.modified = magenta bold
status.added = green bold
status.removed = red bold
status.deleted = cyan bold
status.unknown = black bold
status.ignored = black bold
Sometimes, rarely, you may need a few further improvements for the
pager extension. I recommend you don't enable these unless you feel
like paging isn't working correctly:
[pager]
# Some options for the less pager, see less(1) for their meaning.
pager = LESS='FSRX' less
# Some commands that aren't paged by default; also enable paging
# for them
attend = tags, help, annotate, cat, diff, export, status, \
outgoing, incoming
You should immediately notice a difference when using CLI hg when you
enable these. Of these options, the only one that enables a new
command is graphlog. I recommend you get in the habit of doing "hg
glog" instead of "hg log" so you can get a better feel for what your
commits are being based on.
- Jordi G. H.
- Some basic hg tips to improve usability,
Jordi Gutiérrez Hermoso <=