Anton Shestakov <av6@dwimlabs.net> [Sun, 19 Nov 2017 13:18:54 +0800] rev 35093
context: add instabilities() method to basefilectx
This method is now used in webutils.commonentry(), which adds common data items
(commit hash, author, date, etc) for rendering changesets in hgweb. Usually,
commonentry() is given a changectx as ctx; but in views related to files (e.g.
file view, diff, annotate) it's replaced by a filectx, so the latter also needs
to have instabilities() method.
Boris Feld <boris.feld@octobus.net> [Sun, 19 Nov 2017 04:11:21 +0100] rev 35092
run-test: drop 'execfile' usage for 'common-pattern.py' file
This is required for Python 3.
Boris Feld <boris.feld@octobus.net> [Sun, 19 Nov 2017 04:10:55 +0100] rev 35091
run-test: use byte for 'common-pattern.py' path
This is required for Python 3.
Jordi Gutiérrez Hermoso <jordigh@octave.org> [Mon, 20 Nov 2017 14:30:54 -0500] rev 35090
templates: reword 'back to filelog' link anchor text
This anchor text is problematic in two ways: first, the "back to" part
assumes that you got to the page showing it via the filelog. This is
not necessarily true, as there are other ways to get to that view
besides the filelog view, such as for example following the history of
lines from a file. Second, it uses "filelog" jargon, which refers to
how each file has its own revlog. This is internal jargon that has no
business being exposed to the end user.
I just reworded this template to improve understanding.
Anton Shestakov <av6@dwimlabs.net> [Sat, 18 Nov 2017 12:04:08 +0800] rev 35089
hgweb: show obsolescence status of a commit
As with phases, spartan theme shows a simple "obsolete: yes" on its own line
(this allows replacing "yes" with something more useful in future, like output
of obsfate* template functions). Everywhere else a new "tag" is added to the
same line that has phase, branch, etc of a changeset; in gitweb and monoblue
the element has gray background, in paper and coal the element is gray with a
dashed underline.
Anton Shestakov <av6@dwimlabs.net> [Sat, 18 Nov 2017 11:58:57 +0800] rev 35088
context: add obsolete() method to basefilectx
This method is now used in webutils.commonentry(), which adds common data items
(commit hash, author, date, etc) for rendering changesets in hgweb. Usually,
commonentry() is given a changectx as ctx; but in views related to files (e.g.
file view, diff, annotate) it's replaced by a filectx, so the latter also needs
to have obsolete() method.
Anton Shestakov <av6@dwimlabs.net> [Sat, 18 Nov 2017 13:00:47 +0800] rev 35087
check-code: grep's context flags don't need an extra space before number
A bit of useless trivia found while researching this: OpenBSD's grep's -C has a
default value (of 2) and disallows space before the argument (while -A and -B
allow).
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35086
dirstate: make map implementation overridable
Other implementations of dirstate will want to replace the class used for the
dirstate map. Allow this to happen by making the class an attribute of the
dirstate.
Differential Revision: https://phab.mercurial-scm.org/D1347
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35085
fsmonitor: only access inner dirstate map if it is available
As part of the dirstate refactor, fsmonitor was updated to directly access the
inner map of the dirstatemap object.
Dirstatemap reimplementations may not use a map like this, so only access it if
it is there.
Differential Revision: https://phab.mercurial-scm.org/D1346
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35084
dirstate: add explicit methods for querying directories (API)
The set-like object returned by dirstate.dirs may be difficult for other
implementations of the dirstate to provide, and is unnecessary as it is
only ever used for __contains__. Instead, provide an explicit method for
testing for a directory.
.. api::
dirstate no longer provides a `dirs()` method. To test for the existence of
a directory in the dirstate, use `dirstate.hasdir(dirname)`.
Differential Revision: https://phab.mercurial-scm.org/D1345
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35083
dirstate: remove _droppath method
This method now doesn't do very much interesting and can be removed. The
updated files set can be updated where _droppath was originally called.
Differential Revision: https://phab.mercurial-scm.org/D1344
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35082
dirstate: move dropping of folded filenames into the dirstate map
When dropping files from the dirstate, the corresponding entry in the
filefoldmap is also dropped. Move this into the dirstate map object. A future
implementation of the dirstate will maintain the filefoldmap differently.
Differential Revision: https://phab.mercurial-scm.org/D1343
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35081
dirstate: move management of the dirstate dirs into the dirstatemap
The dirstate dirs object is owned by the map, so move management of that object
there. A future implementation of the dirstate will manage the dirs object
differently.
Differential Revision: https://phab.mercurial-scm.org/D1342
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35080
dirstate: move management of nonnormal sets into dirstate map
The dirstate map owns the nonnormal sets, and so should be the class to update
them. A future implementation of the dirstate will manage these maps
differently.
The action of clearing ambiguous times is now entirely controlled by the
dirstate map, so it moves there too.
Differential Revision: https://phab.mercurial-scm.org/D1341
Mark Thomas <mbthomas@fb.com> [Wed, 15 Nov 2017 01:07:42 -0800] rev 35079
dirstate: add explicit methods for modifying dirstate
Instead of assigning dirstatetuple objects to entries in the dirstate, move
responsibility for creating tuples into the dirstatemap.
Differential Revision: https://phab.mercurial-scm.org/D1340