Sat, 12 May 2018 18:44:03 -0700 packaging: dynamically define make targets
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 May 2018 18:44:03 -0700] rev 38460
packaging: dynamically define make targets We currently have make boilerplate for each instance of a distro's release. This is redundant, annoying to maintain, and prone to errors. This commit defines variables holding available releases for various distros. We then iterate through the list and dynamically define make targets. Differential Revision: https://phab.mercurial-scm.org/D3761
Sat, 12 May 2018 14:41:48 -0700 packaging: don't write files for templatized Dockerfiles
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 May 2018 14:41:48 -0700] rev 38459
packaging: don't write files for templatized Dockerfiles Now that Docker image building is implemented in Python and we can perform template substitution in memory, we don't need to write out produced Dockerfiles to disk. Differential Revision: https://phab.mercurial-scm.org/D3760
Sat, 12 May 2018 17:03:47 -0700 packaging: replace dockerlib.sh with a Python script
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 May 2018 17:03:47 -0700] rev 38458
packaging: replace dockerlib.sh with a Python script I want to do some more advanced things with Docker in upcoming commits. Trying to do that with shell scripts will be a bit too painful for my liking. Implementing things in Python will be vastly simpler in the long run. This commit essentially ports dockerlib.sh to a Python script. dockerdeb and dockerrpm have been ported to use the new hg-docker script. hg-docker requires Python 3. I've only tested on Python 3.5. Unlike the local packaging scripts which may need to run on old distros, the Docker packaging scripts don't have these constraints. So I think it is acceptable to require Python 3.5. As part of the transition, the Docker image tags changed slightly. I don't think that's a big deal: the Docker image names are effectively arbitrary and are a means to an end to achieve running commands in Docker containers. The code for resolving the Dockerfile content allows substituting values passed as arguments. This will be used in a subsequent commit. Differential Revision: https://phab.mercurial-scm.org/D3759
Sat, 12 May 2018 15:51:37 -0700 packaging: consistently create build user in Dockerfiles
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 May 2018 15:51:37 -0700] rev 38457
packaging: consistently create build user in Dockerfiles Previously, dockerlib.sh appended some commands to create a "build" user in each Docker image. The resulting Docker images could be inconsistent depending on the execution environment and base image. With this change, we explicitly create our custom user and group as the first action in each Dockerfile. The user always has user:group 1000:1000 and all built images are consistent. We also create a home directory for the user under /build. This directory is currently ignored. As part of this, we stop setting the DBUILDUSER variable in dockerlib.sh and instead set it in the respective scripts that call it. This is in preparation for further refactoring of dockerlib.sh. Differential Revision: https://phab.mercurial-scm.org/D3758
Fri, 15 Jun 2018 00:50:48 +0530 scmutil: move construction of instability count message to separate fn
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 15 Jun 2018 00:50:48 +0530] rev 38456
scmutil: move construction of instability count message to separate fn When the commad we are running, introduces new instabilities, we show a message like `5 new orphan changesets`, `2 new content-divergent changesets`, `1 new phase-divergent changesets` etc which is very nice. Now taking a step ahead, we want users to show how to fix them too. Something like: `5 new orphan changesets (run 'hg evolve' to resolve/stabilize them)` `2 new content-divergent changesets (run 'hg evolve --content-divergent' to resolve them)` and maybe telling user a way to understand more about those new instabilities like `hg evolve --list` or `hg log -r 'orphan()'` something like that. The idea came from issue5855 which I want to fix because fixing that will result in a nice UI. Taking the construction logic out will allow extensions like evolve (maybe rebase too) to wrap that and add information about how to resolve and how to understand the instability more. Differential Revision: https://phab.mercurial-scm.org/D3734
Mon, 25 Jun 2018 16:36:14 +0200 procutil: use unbuffered stdout on Windows stable 4.6.2
Sune Foldager <cryo@cyanite.org> [Mon, 25 Jun 2018 16:36:14 +0200] rev 38455
procutil: use unbuffered stdout on Windows Windows doesn't support line buffering, treating it as fully buffered. This causes output of slow commands to stutter. We use unbuffered instead.
Mon, 25 Jun 2018 16:36:14 +0200 procutil: use unbuffered stdout on Windows
Sune Foldager <cryo@cyanite.org> [Mon, 25 Jun 2018 16:36:14 +0200] rev 38454
procutil: use unbuffered stdout on Windows Windows doesn't support line buffering, treating it as fully buffered. This causes output of slow commands to stutter. We use unbuffered instead.
Fri, 25 May 2018 18:16:38 +0530 graft: introduce --abort flag to abort interrupted graft
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 25 May 2018 18:16:38 +0530] rev 38453
graft: introduce --abort flag to abort interrupted graft This patch introduces a new --abort flag to `hg graft` command which aborts an interrupted graft and rollbacks to the state before graft. The behavior when some of grafted changeset get's published while interrupted graft or we have new descendants on grafted changesets is same as that of rebase which is warn the user, don't strip and abort the abort the graft. Tests are added for the new flag. .. feature:: `hg graft` now has a `--abort` flag which aborts the interrupted graft and rollbacks to state before the graft. Differential Revision: https://phab.mercurial-scm.org/D3754
Fri, 15 Jun 2018 02:46:34 +0530 graft: move `if continue` to elif and add new line
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 15 Jun 2018 02:46:34 +0530] rev 38452
graft: move `if continue` to elif and add new line This will make upcoming patch where we introduce a new elif for the abort case more readable. Also added a new line before the if-else starts. Differential Revision: https://phab.mercurial-scm.org/D3752
Fri, 15 Jun 2018 02:34:27 +0530 graft: start storing new nodes formed in graftstate
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 15 Jun 2018 02:34:27 +0530] rev 38451
graft: start storing new nodes formed in graftstate This patch starts storing the new nodes formed during the ongoing graft operation in the graftstate. We need the list of new nodes formed while implmenting `graft --abort` which will strip out the new nodes. Differential Revision: https://phab.mercurial-scm.org/D3751
Thu, 14 Jun 2018 23:22:51 +0900 show: use filter() function to strip "tip" tag
Yuya Nishihara <yuya@tcha.org> [Thu, 14 Jun 2018 23:22:51 +0900] rev 38450
show: use filter() function to strip "tip" tag Before, an empty tag "" was inserted in place of "tip", resulting in double spaces.
Thu, 14 Jun 2018 23:10:14 +0900 templater: extend filter() to accept template expression for emptiness test
Yuya Nishihara <yuya@tcha.org> [Thu, 14 Jun 2018 23:10:14 +0900] rev 38449
templater: extend filter() to accept template expression for emptiness test This utilizes the pass-by-name nature of template arguments.
Thu, 14 Jun 2018 22:33:26 +0900 templater: introduce filter() function to remove empty items from list
Yuya Nishihara <yuya@tcha.org> [Thu, 14 Jun 2018 22:33:26 +0900] rev 38448
templater: introduce filter() function to remove empty items from list The primary use case is to filter out "tip" from a list of tags.
Sun, 17 Jun 2018 16:10:38 +0900 templater: fix truth testing of integer 0 taken from a list/dict
Yuya Nishihara <yuya@tcha.org> [Sun, 17 Jun 2018 16:10:38 +0900] rev 38447
templater: fix truth testing of integer 0 taken from a list/dict Broken at f9c426385853. bool(python_value) shouldn't be used here since an integer 0 has to be truthy for backward compatibility.
Mon, 18 Jun 2018 21:58:04 +0900 formatter: look for template symbols from the associated name
Yuya Nishihara <yuya@tcha.org> [Mon, 18 Jun 2018 21:58:04 +0900] rev 38446
formatter: look for template symbols from the associated name Otherwise symbolsused() would fail if a named template is specified with -T.
Mon, 25 Jun 2018 15:54:56 +0530 py3: add b'' prefixes in tests/test-obsolete-divergent.t
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 25 Jun 2018 15:54:56 +0530] rev 38445
py3: add b'' prefixes in tests/test-obsolete-divergent.t This makes the test pass on Python 3. # skip-blame because just b'' prefixes. Differential Revision: https://phab.mercurial-scm.org/D3832
Mon, 25 Jun 2018 01:07:23 +0530 py3: use stringutil.pprint() to print NoneType
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 25 Jun 2018 01:07:23 +0530] rev 38444
py3: use stringutil.pprint() to print NoneType Before this patch, when running test-debugcommands.t, we get a TypeError because NoneType can't be converted into bytes. This patch uses stringutil.pprint() to print the ui._colormode. We are now close to getting test-debugcommands.t passing on Python 3. Differential Revision: https://phab.mercurial-scm.org/D3831
Sat, 23 Jun 2018 08:59:18 +0530 rebase: make dry-run return 1 or 0 according to result
Sushil khanchi <sushilkhanchi97@gmail.com> [Sat, 23 Jun 2018 08:59:18 +0530] rev 38443
rebase: make dry-run return 1 or 0 according to result In dry-run mode, if there is no conflict return 0, if any then return 1 Differential Revision: https://phab.mercurial-scm.org/D3829
Fri, 24 Mar 2017 00:33:35 -0400 relink: use context manager for lock management
Matt Harbison <matt_harbison@yahoo.com> [Fri, 24 Mar 2017 00:33:35 -0400] rev 38442
relink: use context manager for lock management
Fri, 24 Mar 2017 00:32:31 -0400 censor: use context manager for lock management
Matt Harbison <matt_harbison@yahoo.com> [Fri, 24 Mar 2017 00:32:31 -0400] rev 38441
censor: use context manager for lock management
Thu, 21 Jun 2018 22:33:42 +0900 templater: remove redundant member variables from templater class
Yuya Nishihara <yuya@tcha.org> [Thu, 21 Jun 2018 22:33:42 +0900] rev 38440
templater: remove redundant member variables from templater class We no longer need them since the engine is instantiated in __init__().
Thu, 21 Jun 2018 22:27:30 +0900 templater: resurrect cache of engine instance
Yuya Nishihara <yuya@tcha.org> [Thu, 21 Jun 2018 22:27:30 +0900] rev 38439
templater: resurrect cache of engine instance The engine-level cache was effectively disabled at 48289eafb37d "templater: drop extension point of engine classes (API)" by mistake, which made template rendering quite slow. Spotted by Martin von Zweigbergk.
Thu, 21 Jun 2018 22:23:43 +0900 templater: extract template loader to separate class
Yuya Nishihara <yuya@tcha.org> [Thu, 21 Jun 2018 22:23:43 +0900] rev 38438
templater: extract template loader to separate class This avoids reference cycle in the subsequent patch: templater -> _proc -> templater.load -> templater The templater class will be a thin wrapper around the loader and the engine.
Sat, 16 Jun 2018 14:34:35 +0900 tests: rename and document test-command-template.t
Yuya Nishihara <yuya@tcha.org> [Sat, 16 Jun 2018 14:34:35 +0900] rev 38437
tests: rename and document test-command-template.t So that we can specify templater tests as test-template-*. (original) $ wc -l test-command-template.t test-template-* 5041 test-command-template.t 23 test-template-filters.t 5064 total (at this patch) $ wc -l test-template-* 1088 test-template-basic.t 1376 test-template-functions.t 1195 test-template-keywords.t 1760 test-template-map.t 5419 total
Sat, 16 Jun 2018 14:14:52 +0900 tests: extract test-template-keywords.t from test-command-template.t
Yuya Nishihara <yuya@tcha.org> [Sat, 16 Jun 2018 14:14:52 +0900] rev 38436
tests: extract test-template-keywords.t from test-command-template.t
Sat, 16 Jun 2018 14:10:12 +0900 tests: fold test-template-filters.t into test-template-functions.t
Yuya Nishihara <yuya@tcha.org> [Sat, 16 Jun 2018 14:10:12 +0900] rev 38435
tests: fold test-template-filters.t into test-template-functions.t
Sat, 16 Jun 2018 13:17:11 +0900 tests: extract test-template-functions.t from test-command-template.t
Yuya Nishihara <yuya@tcha.org> [Sat, 16 Jun 2018 13:17:11 +0900] rev 38434
tests: extract test-template-functions.t from test-command-template.t I decided to not split filters and functions into two test files since we sometimes reimplement a filter as a function.
Sat, 16 Jun 2018 12:37:43 +0900 tests: extract test-template-map.t from test-command-template.t
Yuya Nishihara <yuya@tcha.org> [Sat, 16 Jun 2018 12:37:43 +0900] rev 38433
tests: extract test-template-map.t from test-command-template.t test-command-template.t is one of the slowest tests. Let's split it into 4 files of manageable size.
Thu, 21 Jun 2018 08:22:11 -0700 cleanupnodes: preserve phase of parents of new nodes
Martin von Zweigbergk <martinvonz@google.com> [Thu, 21 Jun 2018 08:22:11 -0700] rev 38432
cleanupnodes: preserve phase of parents of new nodes As Yuya noted in the review of D3818, passing in targetphase=phases.draft would result in advancing the phase boundary of a secret-phase parent. We never pass targetphase=phases.draft so far, but it's a bug waiting to happen. I tried to refactor it so max(parentphase, X) happened in one place, but I couldn't come up with good variables names and I ended up with a "newphase = max(newphase, parentphase)" line, which made the whole block not look any better to me. Differential Revision: https://phab.mercurial-scm.org/D3824
Sat, 16 Jun 2018 18:36:25 +0530 rebase: delete the comment which was not following "do not eat my data"
Sushil khanchi <sushilkhanchi97@gmail.com> [Sat, 16 Jun 2018 18:36:25 +0530] rev 38431
rebase: delete the comment which was not following "do not eat my data" Differential Revision: https://phab.mercurial-scm.org/D3756
Fri, 08 Jun 2018 22:16:23 +0900 tags: unblock log-like template keywords and functions
Yuya Nishihara <yuya@tcha.org> [Fri, 08 Jun 2018 22:16:23 +0900] rev 38430
tags: unblock log-like template keywords and functions It checks if ctx will be used in template since loading ctx per revision could take extra 10-100msec in total depending on the number of tags.
Fri, 08 Jun 2018 22:10:22 +0900 formatter: provide hint of context keys required by template
Yuya Nishihara <yuya@tcha.org> [Fri, 08 Jun 2018 22:10:22 +0900] rev 38429
formatter: provide hint of context keys required by template This allows us to create ctx objects only if necessary. I tried another idea which is to populate ctx from 'repo' and 'node' value on demand. It worked, but seemed unnecessarily complicated. So I chose a simpler one. The datafields argument is a space-separated string for consistency with fm.write() API.
Thu, 14 Jun 2018 21:18:58 +0900 templatefuncs: declare resource requirements for future use
Yuya Nishihara <yuya@tcha.org> [Thu, 14 Jun 2018 21:18:58 +0900] rev 38428
templatefuncs: declare resource requirements for future use
Thu, 14 Jun 2018 21:17:56 +0900 templatefuncs: minimize resource requirements
Yuya Nishihara <yuya@tcha.org> [Thu, 14 Jun 2018 21:17:56 +0900] rev 38427
templatefuncs: minimize resource requirements
Thu, 21 Jun 2018 09:32:31 -0700 merge with stable
Martin von Zweigbergk <martinvonz@google.com> [Thu, 21 Jun 2018 09:32:31 -0700] rev 38426
merge with stable
Tue, 19 Jun 2018 22:45:52 +0900 merge: do not fill manifest of committed revision with pseudo node (issue5526) stable
Yuya Nishihara <yuya@tcha.org> [Tue, 19 Jun 2018 22:45:52 +0900] rev 38425
merge: do not fill manifest of committed revision with pseudo node (issue5526) Since a75d24539aba "convert: fix convert dropping p2 contents during filemap merge", wctx is not always a committablectx because the convert extension passes in repo[n] as wctx. If wctx is a committed changeset, its manifest dict shouldn't be mutated reflecting to the working directory.
Tue, 19 Jun 2018 13:49:06 -0700 split: preserve phase of commit that is being split
Martin von Zweigbergk <martinvonz@google.com> [Tue, 19 Jun 2018 13:49:06 -0700] rev 38424
split: preserve phase of commit that is being split With this change, hg split will preserve the phase of the commit that is being split, ignoring the phases.new-commit setting. Previously, we would use whatever phases.new-commit was set to (unless our parent was secret, then we would be secret even if phases.new-commit=draft). Now, splitting a draft commit with phases.new-commit=secret does not cause the new commits to become secret, and splitting a secret commit with phases.new-commit=draft and a draft parent does not cause the new commits to become draft. Test cases and commit message taken from Kyle Lippincott's D2016 (thanks!). Differential Revision: https://phab.mercurial-scm.org/D3819
Tue, 19 Jun 2018 11:07:40 -0700 scmutil: make cleanupnodes optionally also fix the phase
Martin von Zweigbergk <martinvonz@google.com> [Tue, 19 Jun 2018 11:07:40 -0700] rev 38423
scmutil: make cleanupnodes optionally also fix the phase We have had multiple bugs where the phase wasn't correctly carried forward to a rewritten changeset (for example: phabricator, split, evolve, fix). Handling the phase update in cleanupnodes() makes it less likely to happen again, especially once we have made it fix the phase by default (perhaps in the next release cycle). This patch also updates all applicable callers so we get some testing of it. Note that rebase and histedit can't be fixed yet because they call cleanupnodes() only at the end and the phase may have been changed by the user when the rebase/histedit was interrupted (due to merge conflicts). I think we should make them write one commit at a time (as it already does), along with associated obsmarkers, bookmark moves, etc. When that's done, we can switch them over to cleanupnodes(). Differential Revision: https://phab.mercurial-scm.org/D3818
Tue, 19 Jun 2018 11:07:23 -0700 tests: add test of uncommit with default phase as secret
Martin von Zweigbergk <martinvonz@google.com> [Tue, 19 Jun 2018 11:07:23 -0700] rev 38422
tests: add test of uncommit with default phase as secret We didn't seem to have any test checking that uncommitting a draft commit with phase.new-phase=secret preserved the draft phase. Differential Revision: https://phab.mercurial-scm.org/D3817
Sun, 17 Jun 2018 15:52:08 +0530 grep: add --diff flag
Sangeet Kumar Mishra <mail2sangeetmishra@gmail.com> [Sun, 17 Jun 2018 15:52:08 +0530] rev 38421
grep: add --diff flag Adds a diff flag, which works exactly same as all, in fact since --all searches diffs, there diff is a better name for it. The all flag is still here for backward compatibility reasons. Some major tests for all has been picked and added for diff. Differential Revision: https://phab.mercurial-scm.org/D3763
Wed, 20 Jun 2018 09:27:30 -0700 fix: include cleanupnodes() in transaction
Martin von Zweigbergk <martinvonz@google.com> [Wed, 20 Jun 2018 09:27:30 -0700] rev 38420
fix: include cleanupnodes() in transaction As pointed out by Yuya, we need a transaction to make sure the state before the call to cleanupnodes() is not observable. Differential Revision: https://phab.mercurial-scm.org/D3823
Tue, 19 Jun 2018 22:19:37 -0700 progress: enforce use of complete() on the helper class
Martin von Zweigbergk <martinvonz@google.com> [Tue, 19 Jun 2018 22:19:37 -0700] rev 38419
progress: enforce use of complete() on the helper class complete() is preferred over update(None), so let's enforce that. Differential Revision: https://phab.mercurial-scm.org/D3822
Tue, 19 Jun 2018 22:11:34 -0700 progress: extract function for closing topic
Martin von Zweigbergk <martinvonz@google.com> [Tue, 19 Jun 2018 22:11:34 -0700] rev 38418
progress: extract function for closing topic progress(None) had a completely different implementation from the progress(<not None>) implementation. It very much feels like it should be a separate method, so this patch makes it so. That also makes it clear that only the topic parameter matters when closing a topic (e.g. "total" does not matter). Differential Revision: https://phab.mercurial-scm.org/D3821
Tue, 19 Jun 2018 22:06:28 -0700 progress: use context manager for lock
Martin von Zweigbergk <martinvonz@google.com> [Tue, 19 Jun 2018 22:06:28 -0700] rev 38417
progress: use context manager for lock Differential Revision: https://phab.mercurial-scm.org/D3820
Tue, 19 Jun 2018 18:21:37 +0200 configitem: reorder items in the 'server' section
Boris Feld <boris.feld@octobus.net> [Tue, 19 Jun 2018 18:21:37 +0200] rev 38416
configitem: reorder items in the 'server' section Keeping things alphabetically sorted.
Thu, 21 Jun 2018 00:48:59 -0400 test-lfs: add coverage for the binary() fileset
Matt Harbison <matt_harbison@yahoo.com> [Thu, 21 Jun 2018 00:48:59 -0400] rev 38415
test-lfs: add coverage for the binary() fileset This ensures that the blobs don't need to be present to be filtered properly.
Thu, 21 Jun 2018 00:05:26 -0400 fileset: use filectx.isbinary() to filter out binaries in eol()
Matt Harbison <matt_harbison@yahoo.com> [Thu, 21 Jun 2018 00:05:26 -0400] rev 38414
fileset: use filectx.isbinary() to filter out binaries in eol() Since LFS stores the binary attribute in the pointer file, this means that the file doesn't need to be downloaded in order to be skipped. This function also catches an IOError if the data can't be loaded in the non-LFS case. I wonder if it's worth storing the unix/dos attributes in the pointer file as well, though I'd expect LFS files to be binary most of the time.
Tue, 19 Jun 2018 13:07:18 +0300 crecord: re-center display in interactive curses commit on pageup/down
Matti Hamalainen <ccr@tnsp.org> [Tue, 19 Jun 2018 13:07:18 +0300] rev 38413
crecord: re-center display in interactive curses commit on pageup/down A long-standing issue in the crecord (interactive curses commit interface) is that using PageUp/Down to move along longer-than current screen size chunks would "lose" the cursor and not properly re-center. There has been self.recenterdisplayedarea() to do that, but it has not been in use for some reason. Add calls to the appropriate uparrowshiftevent() and downarrowshiftevent() methods to fix this.
Fri, 02 Feb 2018 14:21:04 -0800 tests: in test-split.t, save a "clean" copy of pre-split repo for later use
Kyle Lippincott <spectral@google.com> [Fri, 02 Feb 2018 14:21:04 -0800] rev 38412
tests: in test-split.t, save a "clean" copy of pre-split repo for later use Differential Revision: https://phab.mercurial-scm.org/D2015
Mon, 18 Jun 2018 16:01:06 -0700 tests: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 16:01:06 -0700] rev 38411
tests: use progress helper With this commit, the only in-tree caller of ui.progress() is scmutil.progress(). That means that we could deprecate it. It also means that we can considering inlining it in scmutil.progress. Differential Revision: https://phab.mercurial-scm.org/D3812
Mon, 18 Jun 2018 15:55:38 -0700 changegroup: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 15:55:38 -0700] rev 38410
changegroup: use progress helper Although it looks like this code was micro-optimized, I could not measure any slow-down. Differential Revision: https://phab.mercurial-scm.org/D3811
Mon, 18 Jun 2018 15:17:27 -0700 synthrepo: close progress topics
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 15:17:27 -0700] rev 38409
synthrepo: close progress topics Differential Revision: https://phab.mercurial-scm.org/D3810
Mon, 18 Jun 2018 15:17:10 -0700 synthrepo: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 15:17:10 -0700] rev 38408
synthrepo: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3809
Mon, 18 Jun 2018 15:14:39 -0700 largefiles: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 15:14:39 -0700] rev 38407
largefiles: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3808
Mon, 18 Jun 2018 15:05:52 -0700 convert: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 15:05:52 -0700] rev 38406
convert: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3807
Mon, 18 Jun 2018 14:59:53 -0700 lfs: use progess helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 14:59:53 -0700] rev 38405
lfs: use progess helper Differential Revision: https://phab.mercurial-scm.org/D3806
Mon, 18 Jun 2018 14:52:41 -0700 relink: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 14:52:41 -0700] rev 38404
relink: use progress helper This doesn't use progress.increment() because progress output is skipped for some positions (so we may end up calling "update(0), update(2), update(7)", or similar). Differential Revision: https://phab.mercurial-scm.org/D3805
Mon, 18 Jun 2018 14:34:07 -0700 patchbomb: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 14:34:07 -0700] rev 38403
patchbomb: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3804
Mon, 18 Jun 2018 14:32:12 -0700 patchbomb: don't close unused progress topic
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 14:32:12 -0700] rev 38402
patchbomb: don't close unused progress topic The "writing" topic has not been used since 1830d0cc4bc1 (patchbomb: minor refactoring of mbox functionality, preparing for move, 2011-11-23). Differential Revision: https://phab.mercurial-scm.org/D3803
Mon, 18 Jun 2018 14:29:08 -0700 churn: use progess helper
Martin von Zweigbergk <martinvonz@google.com> [Mon, 18 Jun 2018 14:29:08 -0700] rev 38401
churn: use progess helper Differential Revision: https://phab.mercurial-scm.org/D3802
Sun, 17 Jun 2018 23:54:58 -0700 treediscovery: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:54:58 -0700] rev 38400
treediscovery: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3801
Sun, 17 Jun 2018 23:48:23 -0700 upgrade: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:48:23 -0700] rev 38399
upgrade: use progress helper A minor side-effect is that we no longer print the progress at 0 (and that we don't re-print it at its current value when starting the next manifest/file). Differential Revision: https://phab.mercurial-scm.org/D3800
Sun, 17 Jun 2018 23:49:27 -0700 upgrade: close progress after each revlog
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:49:27 -0700] rev 38398
upgrade: close progress after each revlog IIUC, one is supposed to close each progress topic before strarting a new one. Otherwise the topics are considered nested, which we don't want here. Differential Revision: https://phab.mercurial-scm.org/D3799
Sun, 17 Jun 2018 23:28:00 -0700 verify: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:28:00 -0700] rev 38397
verify: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3798
Sun, 17 Jun 2018 23:35:49 -0700 verify: use progress helper for subdirectory progress
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:35:49 -0700] rev 38396
verify: use progress helper for subdirectory progress I also reworded a variable to make it clearer that it's only used for subdirectories. Differential Revision: https://phab.mercurial-scm.org/D3797
Sun, 17 Jun 2018 23:17:03 -0700 similar: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:17:03 -0700] rev 38395
similar: use progress helper A side-effect is that progress is now reported as 1 *before* we start checking the first file. That seems to be how we do it in most places. Also, the right topic is now closed. Differential Revision: https://phab.mercurial-scm.org/D3796
Sun, 17 Jun 2018 23:13:03 -0700 repair: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:13:03 -0700] rev 38394
repair: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3795
Sun, 17 Jun 2018 23:11:06 -0700 httpconnection: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:11:06 -0700] rev 38393
httpconnection: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3794
Sun, 03 Jun 2018 18:18:36 +0900 py3: byte-stringify literals in contrib/phabricator.py as example
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Jun 2018 18:18:36 +0900] rev 38392
py3: byte-stringify literals in contrib/phabricator.py as example Transformed by contrib/byteify-strings.py and adjusted exceeded lines manually. Some of b''s would be wrong as the phabriactor extension has to work with JSON data. # skip-blame just many b prefixes
Sun, 03 Jun 2018 18:19:54 +0900 byteify-strings: remove superfluous "if True" block
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Jun 2018 18:19:54 +0900] rev 38391
byteify-strings: remove superfluous "if True" block
Fri, 01 Jun 2018 00:13:55 +0900 byteify-strings: try to preserve column alignment
Yuya Nishihara <yuya@tcha.org> [Fri, 01 Jun 2018 00:13:55 +0900] rev 38390
byteify-strings: try to preserve column alignment
Thu, 31 May 2018 23:44:35 +0900 byteify-strings: do not rewrite system string literals to u''
Yuya Nishihara <yuya@tcha.org> [Thu, 31 May 2018 23:44:35 +0900] rev 38389
byteify-strings: do not rewrite system string literals to u'' It would make things worse on Python 2 because unicode processing is generally slower than byte string. We should just leave system strings unmodified.
Thu, 31 May 2018 22:34:23 +0900 byteify-strings: do not rewrite iteritems() and itervalues() by default
Yuya Nishihara <yuya@tcha.org> [Thu, 31 May 2018 22:34:23 +0900] rev 38388
byteify-strings: do not rewrite iteritems() and itervalues() by default We can't do that automatically due to performance concerns.
Thu, 31 May 2018 22:31:37 +0900 byteify-strings: drop import-line hack
Yuya Nishihara <yuya@tcha.org> [Thu, 31 May 2018 22:31:37 +0900] rev 38387
byteify-strings: drop import-line hack This is ugly, and valid only for Python 3. We'll need to find a different way if we want to get rid of the code transformer at all.
Thu, 31 May 2018 22:28:29 +0900 byteify-strings: add --inplace option to write back result
Yuya Nishihara <yuya@tcha.org> [Thu, 31 May 2018 22:28:29 +0900] rev 38386
byteify-strings: add --inplace option to write back result
Thu, 31 May 2018 22:23:30 +0900 byteify-strings: add basic command interface
Yuya Nishihara <yuya@tcha.org> [Thu, 31 May 2018 22:23:30 +0900] rev 38385
byteify-strings: add basic command interface
Thu, 31 May 2018 22:07:04 +0900 byteify-strings: fork py3 code transformer to make it a standalone command
Yuya Nishihara <yuya@tcha.org> [Thu, 31 May 2018 22:07:04 +0900] rev 38384
byteify-strings: fork py3 code transformer to make it a standalone command I'm thinking of making a one-off s/''/b''/g change for overall codebase to make linter happy. We could do that without maintaining the script, but I think it will be somewhat useful for extension authors. So it is in contrib.
Mon, 18 Jun 2018 21:54:52 +0900 highlight: get around tmpl.load() which now returns a parsed tree
Yuya Nishihara <yuya@tcha.org> [Mon, 18 Jun 2018 21:54:52 +0900] rev 38383
highlight: get around tmpl.load() which now returns a parsed tree Broken at e637dc0b3b1f, "templater: parse template string to tree by templater class."
Sun, 17 Jun 2018 23:06:20 -0700 changegroup: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:06:20 -0700] rev 38382
changegroup: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3783
Sun, 17 Jun 2018 23:00:59 -0700 archival: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 23:00:59 -0700] rev 38381
archival: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3782
Sun, 17 Jun 2018 22:57:34 -0700 copystore: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 22:57:34 -0700] rev 38380
copystore: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3781
Sun, 17 Jun 2018 22:09:15 -0700 subrepo: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 22:09:15 -0700] rev 38379
subrepo: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3780
Sun, 17 Jun 2018 22:05:54 -0700 histedit: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 22:05:54 -0700] rev 38378
histedit: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3779
Sun, 17 Jun 2018 22:01:59 -0700 rebase: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 22:01:59 -0700] rev 38377
rebase: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3778
Sun, 17 Jun 2018 21:47:34 -0700 debugbuilddag: use context manager for progress, locks, transaction
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 21:47:34 -0700] rev 38376
debugbuilddag: use context manager for progress, locks, transaction I minor side-effect is that .hg/localtags is now written before the transaction commits. Differential Revision: https://phab.mercurial-scm.org/D3777
Sun, 17 Jun 2018 21:44:57 -0700 debugbuilddag: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 21:44:57 -0700] rev 38375
debugbuilddag: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3776
Sun, 17 Jun 2018 13:48:58 -0700 progress: make the progress helper a context manager
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 13:48:58 -0700] rev 38374
progress: make the progress helper a context manager This lets us simplify the use site in streamclone. Differential Revision: https://phab.mercurial-scm.org/D3775
Sun, 17 Jun 2018 22:13:41 -0700 progress: hide update(None) in a new complete() method
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 22:13:41 -0700] rev 38373
progress: hide update(None) in a new complete() method update(None) seemed a bit cryptic. Differential Revision: https://phab.mercurial-scm.org/D3774
Sat, 16 Jun 2018 08:22:10 +0530 rebase: add dry-run functionality
Sushil khanchi <sushilkhanchi97@gmail.com> [Sat, 16 Jun 2018 08:22:10 +0530] rev 38372
rebase: add dry-run functionality For now, it gives stats about rebase would be successful or hit a conflict. Remaining work is to improve the output and adding verbose mode where will show the diff of conflicting files if we hit any. Differential Revision: https://phab.mercurial-scm.org/D3757
Mon, 18 Jun 2018 16:07:46 +0530 py3: add `and None` to suppress return values of .write() calls
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 16:07:46 +0530] rev 38371
py3: add `and None` to suppress return values of .write() calls .write() calls don't return anything on Python2, so we need to make sure we suppress that on py3 too. This makes the test pass on Python 3. Differential Revision: https://phab.mercurial-scm.org/D3793
Mon, 18 Jun 2018 16:06:28 +0530 py3: slice over bytes to prevent getting ascii values
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 16:06:28 +0530] rev 38370
py3: slice over bytes to prevent getting ascii values Differential Revision: https://phab.mercurial-scm.org/D3792
Mon, 18 Jun 2018 16:06:01 +0530 py3: use pycompat.maplist() instead of map() in hgext/transplant.py
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 16:06:01 +0530] rev 38369
py3: use pycompat.maplist() instead of map() in hgext/transplant.py map() returns a map-object on Python3 instead of a list. Differential Revision: https://phab.mercurial-scm.org/D3791
Mon, 18 Jun 2018 15:50:15 +0530 py3: add 4 new passing tests to whitelist
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:50:15 +0530] rev 38368
py3: add 4 new passing tests to whitelist Differential Revision: https://phab.mercurial-scm.org/D3790
Mon, 18 Jun 2018 15:31:13 +0530 py3: make tests/test-impexp-branch.t compatible with Python 3
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:31:13 +0530] rev 38367
py3: make tests/test-impexp-branch.t compatible with Python 3 This patch adds some missig b'' prefixes and add suppress the output of write() calls. Differential Revision: https://phab.mercurial-scm.org/D3789
Mon, 18 Jun 2018 15:28:18 +0530 py3: convert error instances to bytes using pycompat.bytestr()
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:28:18 +0530] rev 38366
py3: convert error instances to bytes using pycompat.bytestr() Differential Revision: https://phab.mercurial-scm.org/D3788
Mon, 18 Jun 2018 15:27:34 +0530 py3: encode sys.argv to bytes using .encode()
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:27:34 +0530] rev 38365
py3: encode sys.argv to bytes using .encode() Differential Revision: https://phab.mercurial-scm.org/D3787
Mon, 18 Jun 2018 15:25:57 +0530 py3: use '%d' for os.stat_result.st_nlink instead of '%s'
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:25:57 +0530] rev 38364
py3: use '%d' for os.stat_result.st_nlink instead of '%s' Differential Revision: https://phab.mercurial-scm.org/D3786
Mon, 18 Jun 2018 15:24:17 +0530 py3: suppress the output of .write() calls in tests/test-revlog-v2.t
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:24:17 +0530] rev 38363
py3: suppress the output of .write() calls in tests/test-revlog-v2.t This makes the test pass on Python 3. Differential Revision: https://phab.mercurial-scm.org/D3785
Mon, 18 Jun 2018 15:23:25 +0530 py3: add couple of missing b'' prefixes in tests/test-pager-legacy.t
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 18 Jun 2018 15:23:25 +0530] rev 38362
py3: add couple of missing b'' prefixes in tests/test-pager-legacy.t # skip-blame because just b'' prefixes Differential Revision: https://phab.mercurial-scm.org/D3784
Thu, 14 Jun 2018 15:17:47 -0700 import: use context manager for lock, dirstateguard, transaction
Martin von Zweigbergk <martinvonz@google.com> [Thu, 14 Jun 2018 15:17:47 -0700] rev 38361
import: use context manager for lock, dirstateguard, transaction A tiny side-effect is that the transaction is now closed after saving the commit message. Differential Revision: https://phab.mercurial-scm.org/D3748
Sun, 17 Jun 2018 23:03:23 -0400 streamclone: update progress later to avoid passing None to util.bytecount
Augie Fackler <raf@durin42.com> [Sun, 17 Jun 2018 23:03:23 -0400] rev 38360
streamclone: update progress later to avoid passing None to util.bytecount Differential Revision: https://phab.mercurial-scm.org/D3773
Sun, 17 Jun 2018 23:00:08 -0400 highlight: adjust to attribute being private
Augie Fackler <raf@durin42.com> [Sun, 17 Jun 2018 23:00:08 -0400] rev 38359
highlight: adjust to attribute being private Differential Revision: https://phab.mercurial-scm.org/D3772
Thu, 03 May 2018 12:04:36 +0900 annotate: automatically populate fields referenced from template
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 12:04:36 +0900] rev 38358
annotate: automatically populate fields referenced from template If '{line_number}' is in the template, we'll probably need it. No --line-number option should be required in such cases.
Thu, 03 May 2018 12:10:47 +0900 annotate: reverse mapping between option name and field name
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 12:10:47 +0900] rev 38357
annotate: reverse mapping between option name and field name This makes the next patch slightly simpler.
Thu, 03 May 2018 11:56:49 +0900 formatter: provide hint of referenced field names
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 11:56:49 +0900] rev 38356
formatter: provide hint of referenced field names I don't like the function name, but I call it datahint() for consistency with another function I'll add later, fm.contexthint().
Thu, 03 May 2018 11:53:56 +0900 templater: add function to look up symbols used in template
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 11:53:56 +0900] rev 38355
templater: add function to look up symbols used in template Formatter can use this information to enable slow paths such as loading ctx object only when necessary.
Thu, 03 May 2018 11:17:52 +0900 templater: parse template string to tree by templater class
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 11:17:52 +0900] rev 38354
templater: parse template string to tree by templater class The parsed tree could be cached, but it isn't for now. We can add a cache later if that matters.
Thu, 03 May 2018 10:58:56 +0900 templater: drop extension point of engine classes (API)
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 10:58:56 +0900] rev 38353
templater: drop extension point of engine classes (API) I don't think this would ever be used by third-party extensions, as we've heavily changed both the templater internals and the syntax since then. The main reason of removing this API is that I want to move the parsing function from the engine to the templater class so that we can peek keywords and functions used in a user template. This change also removes reference cycle between the templater and the engine.
Thu, 03 May 2018 11:09:27 +0900 templater: make it clearer that parsing doesn't cause recursion
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 11:09:27 +0900] rev 38352
templater: make it clearer that parsing doesn't cause recursion Only compileexp() may recurse into _load().
Thu, 03 May 2018 10:53:29 +0900 templater: mark most attributes as private
Yuya Nishihara <yuya@tcha.org> [Thu, 03 May 2018 10:53:29 +0900] rev 38351
templater: mark most attributes as private
Sun, 17 Jun 2018 06:23:29 -0700 setdiscovery: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sun, 17 Jun 2018 06:23:29 -0700] rev 38350
setdiscovery: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3770
Sat, 16 Jun 2018 00:37:44 -0700 streamclone: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sat, 16 Jun 2018 00:37:44 -0700] rev 38349
streamclone: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3769
Sat, 16 Jun 2018 00:25:13 -0700 similar: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sat, 16 Jun 2018 00:25:13 -0700] rev 38348
similar: use progress helper Note that a functional change here is that we now show the progress position *before* we start working on the item. This is consistent with how we do it elsewhere. Differential Revision: https://phab.mercurial-scm.org/D3768
Sat, 16 Jun 2018 00:03:23 -0700 remove: use progress helper
Martin von Zweigbergk <martinvonz@google.com> [Sat, 16 Jun 2018 00:03:23 -0700] rev 38347
remove: use progress helper Differential Revision: https://phab.mercurial-scm.org/D3767
Fri, 15 Jun 2018 23:04:44 -0700 changegroup: use progress helper in apply() (API)
Martin von Zweigbergk <martinvonz@google.com> [Fri, 15 Jun 2018 23:04:44 -0700] rev 38346
changegroup: use progress helper in apply() (API) Differential Revision: https://phab.mercurial-scm.org/D3766
Fri, 15 Jun 2018 22:37:01 -0700 progress: create helper class for incrementing progress
Martin von Zweigbergk <martinvonz@google.com> [Fri, 15 Jun 2018 22:37:01 -0700] rev 38345
progress: create helper class for incrementing progress When using ui.progress(), there's a clear pattern that is followed: * Pass the same topic and unit * Usually pass the same total * Call with pos=None to close the progress bar * Often keep track of the current position and increment it This patch creates a simple helper class for this. I'll probably make it implement the context manager protocol later (calling update(None) on __exit__). Progress is used in low-level modules like changegroup, so I also exposed it via a method on the ui object. Perhaps the class itself should also live in ui.py? This patch also makes merge.oy use it to show that it works. Differential Revision: https://phab.mercurial-scm.org/D3765
Sun, 17 Jun 2018 18:01:49 +0900 extensions: use context manger for open()
Yuya Nishihara <yuya@tcha.org> [Sun, 17 Jun 2018 18:01:49 +0900] rev 38344
extensions: use context manger for open()
Sun, 17 Jun 2018 17:59:12 +0900 py3: open extension source in binary mode to read docstring as bytes
Yuya Nishihara <yuya@tcha.org> [Sun, 17 Jun 2018 17:59:12 +0900] rev 38343
py3: open extension source in binary mode to read docstring as bytes
Wed, 13 Jun 2018 16:22:54 +0530 grep: adds allfiles mode
Sangeet Kumar Mishra <mail2sangeetmishra@gmail.com> [Wed, 13 Jun 2018 16:22:54 +0530] rev 38342
grep: adds allfiles mode Adds an allfiles flag that lets you grep on all files in the revision and not just the one that were modified in that changeset. This would work on a single revision and get all the files that were there in that revision. So it's like grepping on a previous state. Using this with wdir() :: `hg grep -r "wdir()" --allfiles` is what the default behavior is desired for grep. Support for multiple revisions to be added later. Differential Revision: https://phab.mercurial-scm.org/D3728
Wed, 13 Jun 2018 22:50:32 +0530 morestatus: remove some extra spaces
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 13 Jun 2018 22:50:32 +0530] rev 38341
morestatus: remove some extra spaces The information about unfinished states in `hg status -v` had a lot of spaces which are not required and feels weird. Let's limit the spacing to four spaces. Differential Revision: https://phab.mercurial-scm.org/D3730
(0) -30000 -10000 -3000 -1000 -120 +120 +1000 +3000 +10000 tip