- Jul 14, 2014
-
-
Matt Mackall authored
-
Katsunori FUJIWARA authored
This separation makes it easier to extend/hook building commit text from the specified context. This patch uses 'committext' instead of 'edittext' for names of newly added variable and function, because the former is more purpose specific than the latter, even though 'edittext' in 'buildcommittext' is left as it is to reduce amount of diff.
-
- Jul 12, 2014
-
-
Gregory Szorc authored
-
- Jul 05, 2014
-
-
Katsunori FUJIWARA authored
Before this patch, filemerge slices byte sequence directly to trim conflict markers, but this may cause: - splitting at intermediate multi-byte sequence - incorrect calculation of column width (length of byte sequence is different from columns in display in many cases) This patch uses 'util.ellipsis' to trim custom conflict markers correctly, even if multi-byte characters are used in them.
-
Katsunori FUJIWARA authored
Before this patch, with careless configuration (missing '|firstline' filtering for '{desc}' keyword, for example), '[ui] mergemarkertemplate' can make conflict markers multiple lines. For ordinary users, advantage of allowing '[ui] mergemarkertemplate' to generate multiple lines for customizing seems to be less than advantage of disallowing it for safety. This patch uses only the first line of the conflict marker generated from '[ui] mergemarkertemplate' configuration for safety.
-
Katsunori FUJIWARA authored
Before this patch, 'progress' extension applies 'len' on byte sequence to get column width of it, but it causes incorrect result, when length of byte sequence and columns in display are different from each other in multi-byte characters. This patch uses 'encoding.colwidth' to get column width of items in output line correctly, even if it contains multi-byte characters.
-
Katsunori FUJIWARA authored
Before this patch, 'progress' extension trims items in output line by directly slicing byte sequence, but it may split at intermediate multi-byte sequence. This patch uses 'encoding.trim' to trim items in output line correctly, even if it contains multi-byte characters.
-
Katsunori FUJIWARA authored
-
Katsunori FUJIWARA authored
Before this patch, 'progress' extension applies 'len' on byte sequence to get column width of it, but it causes incorrect result, when length of byte sequence and columns in display are different from each other in multi-byte characters. This patch uses 'encoding.colwidth' to get column width of output line correctly, even if it contains multi-byte characters.
-
Katsunori FUJIWARA authored
Before this patch, 'progress' extension trims output line by directly slicing byte sequence, but it may split at intermediate multi-byte sequence. This patch uses 'encoding.trim' to trim output line correctly, even if it contains multi-byte characters. "rm -f loop.pyc" before changing "loop.py" in "test-progress.t" ensures that re-compilation of "loop.py", even if "loop.py" and "loop.pyc" have same timestamp in seconds.
-
Katsunori FUJIWARA authored
Before this patch, trimming description of each changesets in histedit may split at intermediate multi-byte sequence. This patch uses 'util.ellipsis' to trim description of each changesets instead of directly slicing byte sequence. Even though 'util.ellipsis' adds '...' as ellipsis when specified string is trimmed (= this changes result of trimming), this patch uses it, because: - it can be used without any additional 'import', and - ellipsis seems to be better than just trimming, for usability
-
Katsunori FUJIWARA authored
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'.
-
Katsunori FUJIWARA authored
Newly added 'trim' is used to trim multi-byte characters at most specified columns correctly: directly slicing byte sequence should be replaced with 'encoding.trim', because the former may split at intermediate multi-byte sequence. Slicing unicode sequence ('uslice') and concatenation with ellipsis ('concat') are defined as function, to make enhancement in subsequent patch easier.
-
- Jul 11, 2014
-
-
Matt Mackall authored
This option had very limited utility and counterintuitive behavior and collided unfortunately with the much later -B option. Normally we would no-op such a feature so as to avoid annoying existing scripts. However, we have to weigh that against the silent misbehavior that results when users mistakenly intended to use -B: because -b takes no arg, the bookmark gets interpreted as a normal revision, and gets stripped without removing the associated bookmark, while also not backing up the revision in question. A no-op behavior or warning would only remove the latter half of the misadventure. The only users I can find of this feature were using it in error and have since stopped. The few (if any) remaining users of this feature would be better served by --no-backup.
-
- Nov 08, 2013
-
-
Ben Kehoe authored
-
- Jun 20, 2014
-
-
Katsunori FUJIWARA authored
After this patch, users can invoke editor for the commit message by '--edit' option regardless of '--message'.
-
Katsunori FUJIWARA authored
Before this patch, the name of a newly added option had to be added into each string that was passed to the "checkopt()" internal function: these are white-space-separated list of un-acceptable option names (= "black list" for the specified "opt"). This new option had to be added into multiple strings because each option could belong to only one action of "create", "cleanup", "delete" or "list". In addition to this redundancy, each string passed to "checkopt()" was already too long to include a new one. This patch refactors option combination check to make it easier to add a new option in a subsequent patch. New "checkopt()" only takes one action ("cleanup", "delete" or "list"), and checks whether all explicitly activated options are allowed for it or not (if specified action is activated in "opts"). The "date" entry is listed in "allowables", but commented out, because: - "date" shouldn't be checked for test checking "date" causes unexpected failure of "test-shelve.t", because "run-test.py" puts "[default] shelve = --date '0 0'" into hgrc. - explicitly listing it can advertise that ignoring it is intentional This patch doesn't choose "white list" for the specified "opt", to avoid treating global options.
-
- Jul 09, 2014
-
-
Matt Mackall authored
-
durin42 authored
-
- Jun 10, 2014
-
-
anatoly techtonik authored
This code is based by hg-versions extension (GPLv2) by Markus Zapke-Gruendemann <info@keimlink.de> http://mercurial.selenic.com/wiki/VersionsExtension
-
- Jul 08, 2014
-
-
David Soria Parra authored
In case we have revs to strip, delete the bookmark after the strip succeeds, not beforehand as we might still abort due to dirty working directory, etc.
-
- Jun 13, 2014
-
-
Ryan McElroy authored
This function allows returning only the nth "word" from a string. By default a string is split as by Python's split() function default, but an optional third parameter can also override what string the string is split by.
-
- Jul 04, 2014
-
-
Sean Farley authored
This was mistakenly moved from workingctx to committablectx in 9d56a3359011. Since the method is querying the dirstate, the only logical place is for it to reside is in workingctx.
-
- Jul 02, 2014
-
-
Sean Farley authored
In d2743be1bb06, memctx was changed to inherit from committablectx, this in turn added the 'substate' property to memctx. It turns out that the newcommitphase method tested for this property: def newcommitphase(ui, ctx): commitphase = phases.newcommitphase(ui) substate = getattr(ctx, "substate", None) if not substate: return commitphase Currently, memctx isn't ready to handle substates, nor removed files, so we explicitly must set substate=None to get the old behavior back. In the future, we can decide how memctx should play with substate. For now, this fixes third-party extensions and some internal code dealing with subrepos.
-
- Jul 08, 2014
-
-
Matt Mackall authored
Prior to this, doing "hg rebase -s @foo -d @" would delete @, which is obviously wrong: a primary bookmark should never be automatically deleted. This change blocks the deletion, but doesn't yet properly clean up the divergence: @ should replace @foo.
-
- Jul 03, 2014
-
-
Jim Hague authored
The config documentation specifies the wrong access method in the XMLRPC+email configuration.
-
- Jul 06, 2014
- Jul 05, 2014
-
-
Alex Gaynor authored
Specifically this is observed to happen on the PyPy one gets from homebrew
-
- Jul 03, 2014
-
-
André Sintzoff authored
The definition is already in parsers.c This patch avoids, at least on Mac OS X 10.6.8, build issue since e250b8300e6e
-
- Jun 13, 2014
-
-
Sean Farley authored
We now see the first result of all that refactoring of memctx: we can now diff against a memctx.
-
Sean Farley authored
-
- May 29, 2014
-
-
Sean Farley authored
This is an initial implementation of having a manifest for memctx that computes the hash in the same way that filenodes are computed elsewhere.
-
- Apr 29, 2014
-
-
Sean Farley authored
-
- Aug 14, 2013
-
-
Sean Farley authored
Future patches will allow patch.diff to take a basectx so node1 (and node2) could make hexfunc error out. Instead, we'll call the node function on the context object directly.
-
- Jul 02, 2014
-
-
Matt Mackall authored
-
Matt Mackall authored
-
Matt Mackall authored
-
- Jun 30, 2014
-
-
Wagner Bruna authored
-