hg: avoid auto sharing when the clone destination is remote
Before this patch, when auto sharing is enabled, 'hg.clone()' tries to
create local clone regardless of locality of the clone destination on
the host, and causes failure.
To avoid auto sharing when the clone destination is remote, this patch
adds examination of 'islocal(dest)' before auto sharing in
'hg.clone()'.
'islocal(dest)' is examined after 'sharepool', because:
- the former is more expensive than the latter
- without enabling share extension, the later is always negative
largefiles: ensure lfutil.getstandinmatcher() only matches standins
Previously, simply having the largefiles extension loaded without any largefiles
added would crash when amending with -I. The problem was with no files in the
matcher, the pattern list of files joined with 'standindir' was empty, and
scmutil.match() would match everything. In lfutil.composestandinmatcher(), the
match function is used to test if the file is a standin, and after getting a
false positive, proceeds to call lfutil.splitstandin(). This returns None
because it isn't a standin, which blows up when passed to rmatcher.matchfn().
Manually overriding _always in getstandinmatcher() probably isn't necessary
anymore, but we leave well enough alone on stable. This regressed in
ab618e52788a.
dirstate: add --minimal flag to debugrebuilddirstate
On repositories with hundreds of thousands of files, hg
debugrebuilddirstate causes every dirstate entry to be marked lookup,
and the next hg status can take many minutes.
This adds a --minimal flag that allows us to only rebuild the parts of the
dirstate that are inconsistent. This follows two rules:
1) If a file is in the dirstate but not in the parent manifest, and it is not
marked 'add', it is busted and we should drop it.
2) If a file is not in the dirstate at all, but it is in the parent
manifest, it should be added to the dirstate and we need to mark it as
lookup.
This allows us to fix repositories where the dirstate doesn't match
the manifest much more quickly.
Tested by artificially adding bad dirstate entries (via code) for both cases
above.
tests: make filterpyflakes.py read target files relatively to cwd
Before this patch, 'filterpyflakes.py' reads target files relatively
to own location.
But this prevents third party tools from using it in own source tree,
because their files are placed separately from 'filterpyflakes.py'.
In fact, 'test-check-pyflakes.t', which is the only user of
'filterpyflakes.py', changes current working directory (cwd) to the
root of "test target" source tree before using it. Therefore,
composing the root of source tree in 'filterpyflakes.py' is redundant.
This patch makes 'filterpyflakes.py' read target files relatively to
cwd by invoking 'open()' without any path composition. This also
removes importing 'os' module, because there is no user of it after
this patch.
This is a one of preparation of
issue4677.
monoblue: remove unused elements and related css
Since
91b0ada2d94b and
c9b88695d894, when monoblue was introduced, the code
this patch removes was untouched. Presumably, there supposed to be nice
graphics in the screen corners, but there never were due to:
- the css being commented out
- ids of the elements and of the css selectors being different
- and the png files absent
The "corner" elements were unstyled and didn't affect the rest of the page, so
I think it's safe to remove all this.