A Scalable, User-Friendly Source Control System.
Go to file
FUJIWARA Katsunori 5206a6fd25 util: replace 'ellipsis' implementation by 'encoding.trim'
Before this patch, 'util.ellipsis' tried to avoid splitting at
intermediate multi-byte sequence, but its implementation was incorrect.

Internal function '_ellipsis' trims specified unicode sequence not at
most maxlength 'columns in display', but at most maxlength number of
'unicode characters'.

    def _ellipsis(text, maxlength):
        if len(text) <= maxlength:
            return text, False
        else:
            return "%s..." % (text[:maxlength - 3]), True

In many encodings, number of unicode characters can be different from
columns in display.

This patch replaces 'ellipsis' implementation by 'encoding.trim',
which can trim string at most maxlength columns in display correctly,
even though specified string contains multi-byte characters.

'_ellipsis' is removed in this patch, because it is referred only from
'ellipsis'.
2014-07-06 02:56:41 +09:00
contrib check-code: drop ban on callable() which was restored in Python 3.2 2014-06-23 09:22:53 -04:00
doc gendoc: restore use of callable() since it was readded in Python 3.2 2014-06-23 09:23:57 -04:00
hgext strip: drop -b/--backup option (BC) 2014-07-11 18:04:51 -05:00
i18n i18n-pt_BR: synchronized with dcea22e932ea 2014-06-30 18:52:57 -03:00
mercurial util: replace 'ellipsis' implementation by 'encoding.trim' 2014-07-06 02:56:41 +09:00
tests strip: drop -b/--backup option (BC) 2014-07-11 18:04:51 -05:00
.hgignore packaging: move output directory from build/ to packages/ 2014-05-27 11:52:39 -07:00
.hgsigs Added signature for changeset 3374ef3a74c8 2014-07-01 23:32:18 -05:00
CONTRIBUTORS Add note to CONTRIBUTORS file 2007-11-07 21:10:30 -06:00
COPYING COPYING: refresh with current address from fsf.org 2011-06-02 11:17:02 -05:00
hg hg: add support for HGUNICODEPEDANTRY environment variable 2014-06-23 09:33:07 -04:00
hgeditor Fixed a bashism with the use of $RANDOM in hgeditor. 2010-05-19 18:06:35 +02:00
hgweb.cgi mq: add a warning about uncommitted changes for qfinish 2011-11-10 15:40:34 -06:00
Makefile buildrpm: remove prompt for uncommitted changes - it was a bad idea 2014-05-15 01:48:37 +02:00
README readme: mention how to run in-place 2012-03-02 21:43:55 +02:00
setup.py setup: fixed for Pythons which don't have a CFLAGS 2014-07-05 07:31:08 -07:00

Mercurial
=========

Mercurial is a fast, easy to use, distributed revision control tool
for software developers.

Basic install:

 $ make            # see install targets
 $ make install    # do a system-wide install
 $ hg debuginstall # sanity-check setup
 $ hg              # see help

Running without installing:

 $ make local      # build for inplace usage
 $ ./hg --version  # should show the latest version

See http://mercurial.selenic.com/ for detailed installation
instructions, platform-specific notes, and Mercurial user information.