Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 18:35:34 +0900] rev 31186
patchbomb: pass around ui and revs that are needed for flag template
See the next patch for why.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 18:28:04 +0900] rev 31185
patchbomb: build patch texts by _getpatchmsgs()
Now _getpatchmsgs() knows revision numbers, which allows us to generate flags
by applying a template to changectx objects.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 18:25:17 +0900] rev 31184
patchbomb: drop internal option for pbranch extension (API)
I want to move _getpatches() to _getpatchmsgs() to make sure each patch text
is tied with the corresponding revision number. This helps adding templater
support.
IIRC, the pbranch extension doesn't work with the recent Mercurial versions,
so the removal of this option wouldn't hurt.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 18:16:41 +0900] rev 31183
patchbomb: factor out function that builds a prefix string to patch subject
I'll add templating support.
Yuya Nishihara <yuya@tcha.org> [Sun, 18 Jan 2015 18:04:44 +0900] rev 31182
formatter: add argument to change output file of non-plain formatter
This allows us to build data not written to the console. That would be
doable by ui.pushbuffer()/popbuffer(), but changing the file object seems
cleaner.
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 13:25:30 -0500] rev 31181
schemes: move re construction to module-level and python3-ify
This makes the schemes extension load correctly in Python 3.
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 13:29:50 -0500] rev 31180
dispatch: cope with sys.version being unicode on Python 3
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 13:29:25 -0500] rev 31179
dispatch: allow testedwith to be bytes or str
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 14:09:14 -0500] rev 31178
ui: fix ui.traceback on Python 3
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 14:08:24 -0500] rev 31177
ui: fix opts labeling on ui.warn et al for Python 3
This is a step towards fixing extension load warnings on Python
3. Note that I suspect there are still some bugs in this area and that
things like color won't work, but the code at least executes and
prints text to the console correctly now.
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 12:55:11 -0500] rev 31176
config: add sanity assert that files are opened as binary
This helps with some debugging in Python 3, and shouldn't hurt
anything in Python 2. The unusual construction using getattr is done
so that StringIO/BytesIO instances can be used as well as real files.
Martin von Zweigbergk <martinvonz@google.com> [Mon, 06 Mar 2017 23:21:27 -0800] rev 31175
update: for "noconflict" updates, print "conflicting changes" on conflict
With experimental.updatecheck=noconflict, if the update is aborted
because of conlicts, "uncommitted changes" is not quite
accurate. Let's use "conflicting changes" instead. Also fix the hint
to recomment --clean, not --merge, since that's what we do for other
failed updates.
Martin von Zweigbergk <martinvonz@google.com> [Mon, 06 Mar 2017 23:19:57 -0800] rev 31174
tests: fix test-update-branches to remove non-conflicting file
I was clearly very sloppy when I wrote the test case for
experimental.updatecheck=noconflict. The test case that checks that
one can move between commits with a removed file was deleting a file
that was modified between the source and target commits, which
resulted in a "change/delete" conflict. Since that is a conlict, the
update correctly failed. Let's fix the test by removing a file that is
not modified between the two commits.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 17:08:42 +0900] rev 31173
branches: populate all template keywords in formatter
This is a usage example of fm.context().
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 17:00:07 +0900] rev 31172
formatter: add support for changeset templating
Some formatter-based commands provide fields that are identical to the ones
defined in templatekw, but we had to specify them manually to support all
changeset-based template keywords.
This patch adds fm.context() that populates all templatekw. These keywords
are available only in template output, so we still need to set important
keywords via fm.data() if they should be available in e.g. JSON output.
Currently fm.context() takes only 'ctx' argument. It will eventually be
extended to take 'fctx' to support file-based keywords (e.g. {path}) seen
in hgweb.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 16:38:26 +0900] rev 31171
templatekw: move defaulttmpl constant from changeset_templater
These templates are used when rendering inner lists of some template keywords,
so it makes sense to define them in templatekw. This allows us to reuse them
to create a templateformatter knowing changectx.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 22:04:30 +0900] rev 31170
formatter: drop filters argument from maketemplater()
It's unused now. I want to keep the high-level API simple.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 16:26:58 +0900] rev 31169
templater: port formatnode filter from changeset_templater
This slightly reduces the difference between changeset_templater and formatter,
and helps extending formatter to support changeset templating.
New formatnode() is not a template filter, but a function since a filter
cannot access to ui. And it's marked as DEPRECATED since I think it exists
only for compatibility reasons.
Martin von Zweigbergk <martinvonz@google.com> [Mon, 13 Feb 2017 00:05:55 -0800] rev 31168
update: allow setting default update check to "noconflict"
The new value allows update (linear or not) as long as they don't
result in file merges.
I'm hoping that this value can some day become the default.
Martin von Zweigbergk <martinvonz@google.com> [Mon, 13 Feb 2017 16:03:05 -0800] rev 31167
update: add experimental config for default way of handling dirty wdir
This allows the user to set e.g. experimental.updatecheck=abort to
abort update if the working directory is dirty, but still be able to
override the behavior with e.g. --merge when needed.
I considered adding a --mergelinear option to get back the old
behavior even when experimental.updatecheck=abort is set, but I
couldn't see why anyone would prefer that over --merge.
The default is read in hg.updatetotally(), which means it also applies
to "hg pull -u" and "hg unbundle -u".
Martin von Zweigbergk <martinvonz@google.com> [Mon, 13 Feb 2017 12:58:37 -0800] rev 31166
update: accept --merge to allow merging across topo branches (
issue5125)
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 15:09:19 -0800] rev 31165
merge: combine the "merge" cases in docstring table
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 15:07:01 -0800] rev 31164
merge: combine "dirty" cases in docstring table
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 15:29:34 -0800] rev 31163
merge: clarify non-linear default updates in docstring table
Non-linear updates won't happen by default, regardless of -c/-C.
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 15:02:36 -0800] rev 31162
merge: combine the two "can't happen" cases in docstring table
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 15:00:13 -0800] rev 31161
merge: move "incompatible options" case first in docstring table
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 14:58:53 -0800] rev 31160
merge: make "linear" an input in docstring table
Instead of having two ouputs, it seem simpler to have an addition
input. This will allow further simplification.
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 14:33:17 -0800] rev 31159
merge: drop redundant column in docstring table
The "same" and "cross" columns now have the same values, so let's
combine them into "non-linear".
Martin von Zweigbergk <martinvonz@google.com> [Mon, 27 Feb 2017 14:27:22 -0800] rev 31158
merge: drop obsolete non-linear cases from docstring table
Since
6b1fc09c699a (update: change default destination to tipmost
descendant (
issue4673) (BC), 2016-02-02), non-linear updates can no
longer happen if the user doesn't specify a destination, so we can
drop these case from the table in the docstring of merge.update().
Martin von Zweigbergk <martinvonz@google.com> [Wed, 24 Feb 2016 14:44:14 -0800] rev 31157
revert: move code dealing with deletions closer together
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 14:10:06 -0500] rev 31156
ui: fix configlist on Python 3
Since we're working on bytestrings, we have to use [offset:offset+1]
to get consistent behavior on Python 2 and 3. I've only tested the
_parse_plain closure, not the _parse_quote one, but I have no real
reason to expect the latter to be broken since the fixes were fairly
mechanical.
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 12:55:49 -0500] rev 31155
config: pass some optional args as keywords
This makes it a little more obvious that self.read is being passed as
include, which took me a moment to figure out.
Augie Fackler <raf@durin42.com> [Fri, 03 Mar 2017 13:28:24 -0500] rev 31154
config: load included config files in binary mode
I guess we've been getting lucky that this works in Python 2. This
fixes loading included config files in Python 3 (it used to fail on
the "somebody set up us the BOM" check.)
Durham Goode <durham@fb.com> [Wed, 01 Mar 2017 16:39:48 -0800] rev 31153
manifest: remove _repo from manifestctx objects
We were storing the repo on the manifestctx objects so that they could access
the manifestlog via repo.manifestlog, which would refresh the structure if it
became out of date. This caused probems however when we want to have multiple
manifest logs in memory at once, like when transitioning to tree manifest from
flat manifests, since a tree manifest would try to access sub-trees via
repo.manifestlog[node], which was the flat manifest.
The solution is to just not store the repo, and instead store the manifestlog
that created this context. This removes the invalidation when the in memory
manifestlog becomes out of date, but people should probably not be keeping ctx's
around that long anyway.
Jun Wu <quark@fb.com> [Wed, 01 Mar 2017 15:50:01 -0800] rev 31152
phases: remove experimental.nativephaseskillswitch
The native code has been used for a long time. Therefore drop the
experimental config option.
Durham Goode <durham@fb.com> [Wed, 01 Mar 2017 16:35:57 -0800] rev 31151
manifest: allow specifying the revlog filename
Previously we had hardcoded the manifest filename to be 00manifest.i. In our
external treemanifest extension, we want to allow writing a treemanifest side by
side with a flat manifest, so we need to be able to store the root revisions at
a different location (in our extension we use 00manifesttree.i).
This patches moves the revlog name to a parameter so we can adjust it.
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 03 Mar 2017 15:30:48 +0530] rev 31150
py3: drop unrequired code from __init__.py
Once we are using pycompat.open(), we don't need this hack to convert the
second argument to unicodes. So removing this.
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 03 Mar 2017 13:04:32 +0530] rev 31149
py3: add pycompat.open and replace open() calls
open() requires mode argument as unicodes on Python 3. This patch introduces
pycompat.open() which is inserted to files using transformer and replaces
builtins.open() calls.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Fri, 05 Aug 2016 13:56:10 +0200] rev 31148
localrepo: deprecate 'repo.opener' (API)
The "new" 'repo.vfs' attribute have been around for almost 5 years. I think we
can deprecate the old form now ;-)
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Thu, 02 Mar 2017 03:24:58 +0100] rev 31147
statichttp: use 'repo.vfs' as the main attribute
We are about to deprecate the repo.opener attribute, we prepare the static http
code to be ready for this change.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Thu, 02 Mar 2017 03:23:18 +0100] rev 31146
clonebundle: use 'repo.vfs' instead of 'repo.opener'
The later is a 5 years old form.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Fri, 05 Aug 2016 13:53:45 +0200] rev 31145
localrepo: deprecated 'repo.wopener' (API)
The "new" 'repo.wvfs' attribute have been around for almost 5 years. I think we
can deprecate the old form now ;-)
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Fri, 05 Aug 2016 13:49:05 +0200] rev 31144
localrepo: add some comment about role of various vfs object
This should make things clearer for most people.
Augie Fackler <augie@google.com> [Thu, 19 Jan 2017 16:27:08 -0500] rev 31143
tests: un-nest the `order` repo in test-rebase-scenario-global
This wasn't hurting anything, but it's more in line with how we manage
other tests.
Augie Fackler <augie@google.com> [Mon, 06 Feb 2017 15:19:32 -0500] rev 31142
osx: install bash and zsh completions by default
The zsh location appears to be on the default $fpath for zsh. bash, on
the other hand, appears to have no default location for completion
scripts, so we follow the lead of Apple's Git distribution and select
a semi-arbitrary place in /usr/local for the file.
Durham Goode <durham@fb.com> [Thu, 02 Mar 2017 10:12:40 -0800] rev 31141
util: add allowhardlinks module variable
To enable extensions to enable hardlinks for certain environments, let's move
the 'if False' to be an 'if allowhardlinks' and let extensions modify the
allowhardlinks variable.
Tests on linux ext4 pass with it set to True and to False.
Augie Fackler <raf@durin42.com> [Thu, 02 Mar 2017 20:30:56 -0500] rev 31140
merge with stable
Augie Fackler <raf@durin42.com> [Thu, 02 Mar 2017 20:19:45 -0500] rev 31139
Added signature for changeset
25703b624d27
Augie Fackler <raf@durin42.com> [Thu, 02 Mar 2017 20:19:43 -0500] rev 31138
Added tag 4.1.1 for changeset
25703b624d27
Augie Fackler <raf@durin42.com> [Thu, 02 Mar 2017 20:07:35 -0500] rev 31137
merge with i18n
Wagner Bruna <wbruna@softwareexpress.com.br> [Thu, 02 Mar 2017 11:08:20 -0300] rev 31136
i18n-pt_BR: synchronized with
7074589cf22a
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 01 Mar 2017 16:43:22 +0900] rev 31135
i18n-ja: synchronized with
7074589cf22a
Durham Goode <durham@fb.com> [Wed, 01 Mar 2017 19:51:05 -0800] rev 31134
revert: remove set(mf) because it's O(manifest)
The revert code had a 'set(manifest)' line in it, which has a runtime equivalent
to the size of the manifest. With alternative manifest implementations, like
treemanifest, this can be extra expensive. Let's rewrite it to be O(changes)
instead of O(manifest size).
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Mon, 13 Feb 2017 14:05:24 +0100] rev 31133
share: add --relative flag to store a relative path to the source
Storing a relative path the source repository is useful when exporting
repositories over the network or when they're located on external
drives where the mountpoint isn't always fixed.
Currently, Mercurial interprets paths in `.hg/shared` relative to
$PWD. I suspect this is very much unintentional, and you have to
manually edit `.hg/shared` in order to trigger this behaviour.
However, on the off chance that someone might rely on it, I added a
new capability called 'relshared'. In addition, this makes earlier
versions of Mercurial fail with a graceful error.
I should note that I haven't tested this patch on Windows.
Gregory Szorc <gregory.szorc@gmail.com> [Wed, 15 Feb 2017 11:49:12 -0800] rev 31132
minirst: support passing admonitions into findadmonitions() and parse()
This will allow consumers to declare a custom list of admonitions
to parse. Without this patch, custom admonitions would get removed
when prunecomments() is run. We could add an argument controlling
whether prunecomments() is run. However, it is better to convert
the "paragraph" block to an "admonition" block so consumers don't
have to parse for custom admonitions.
Gregory Szorc <gregory.szorc@gmail.com> [Wed, 15 Feb 2017 11:47:14 -0800] rev 31131
minirst: dynamically compile admonitions regexp
Currently, parsing admonitions uses a static regular expression created
from a pre-defined list of admonitions. A future patch will introduce a
feature that needs to parse custom admonitions. Prepare for this by
compiling the admonitions regular expression during each function
invocation.
Strictly speaking, there is a slight performance loss here. But we only
run this code as part of displaying help text. I don't think the loss
will be noticeable and I don't think we care if it were.
Gregory Szorc <gregory.szorc@gmail.com> [Wed, 15 Feb 2017 16:42:17 -0800] rev 31130
minirst: detect bullet lists using asterisks
Previously, the "bullet" regular expression excluded the asterisk
('*') as a character denoting a bulleted list. Why I'm not sure
because the asterisk seems to be the canonical bullet character
in reST these days.
This patch makes asterisk-prefixed lines parse as bulleted lists.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Wed, 01 Mar 2017 20:22:04 +0100] rev 31129
color: update the help table
We also need to reference the new topic in the great old help table.
Yuya Nishihara <yuya@tcha.org> [Sat, 25 Feb 2017 14:09:55 +0900] rev 31128
ui: remove superfluous indent in _write()
Yuya Nishihara <yuya@tcha.org> [Sat, 18 Feb 2017 17:37:52 +0900] rev 31127
smartset: reorder initialization of baseset in more intuitive way
What we want to do is to assign either _set or _list per the given data
type.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Tue, 28 Feb 2017 20:23:10 +0100] rev 31126
config: update the Windows example config file
We move from the color extensions to the 'ui.color' config.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Tue, 21 Feb 2017 22:53:38 +0100] rev 31125
help: use 'churn' instead of 'color' as an example extension
The 'color' extensions is now deprecated.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Tue, 21 Feb 2017 22:17:33 +0100] rev 31124
config: suggest the 'ui.color' instead of the 'color' extension
The extensions is deprecated now so we should offer the core way to handle color
instead.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Tue, 21 Feb 2017 20:04:55 +0100] rev 31123
color: update main documentation
Now that the feature no longer lives in the extension, we document it in the
help of the core config. This include the new 'ui.color' option introduced in
the previous changesets.
As a result the color extensions can now be deprecated.
This is a documentation patch only; color is still disabled by default.