- Nov 22, 2019
-
-
Augie Fackler authored
I noticed this only because the WiX build was broken after 2e017696181f. I haven't tested this change with WiX, but it seems pretty obvious by inspection this should fix it. Differential Revision: https://phab.mercurial-scm.org/D7472
-
- Nov 16, 2019
-
-
Gregory Szorc authored
These scripts weren't blackened. I found these as part of adding script checking to test-check-format.t. # skip-blame black Differential Revision: https://phab.mercurial-scm.org/D7446
-
Gregory Szorc authored
It appears our mutable default arguments checker doesn't find arguments not on the first line of a function definition :( The arguments aren't used, so the default value is irrelevant. I found this when blackening this script in a future commit. Differential Revision: https://phab.mercurial-scm.org/D7445
-
- Nov 14, 2019
-
-
Martin von Zweigbergk authored
The new resourceutil module is lower in the dependency graph, so we can depend directly on it and won't have to depend on the util module to inject the datapath. Differential Revision: https://phab.mercurial-scm.org/D7435
-
- Nov 08, 2019
-
-
Augie Fackler authored
This is the promised second step on single-quoted strings. These had existed because our source transformer didn't turn r'' into b'', so we had tagged some strings as r-strings to get "native" strings on both Pythons. Now that the transformer is gone, we can dispense with this nonsense. Methodology: I ran hg locate 'set:added() or modified() or clean()' | egrep '.*\.py$' | xargs egrep --color=never -n -- \[\^b\]\[\^a-z\]r\'\[\^\'\\\\\]\*\'\[\^\'\ in an emacs grep-mode buffer, and then used a keyboard macro to iterate over the results and remove the r prefix as needed. # skip-blame removing unneeded r prefixes left over from Python 3 migration. Differential Revision: https://phab.mercurial-scm.org/D7306
-
- Nov 07, 2019
-
-
Augie Fackler authored
This is only double-quoted strings. I'll do single-quoted strings as a second step. These had existed because our source transformer didn't turn r"" into b"", so we had tagged some strings as r-strings to get "native" strings on both Pythons. Now that the transformer is gone, we can dispense with this nonsense. Methodology: I ran hg locate 'set:added() or modified() or clean()' | egrep '.*\.py$' | xargs egrep --color=never -n -- \[\^a-z\]r\"\[\^\"\\\\\]\*\"\[\^\"\] in an emacs grep-mode buffer, and then used a keyboard macro to iterate over the results and remove the r prefix as needed. # skip-blame removing unneeded r prefixes left over from Python 3 migration. Differential Revision: https://phab.mercurial-scm.org/D7305
-
- Oct 07, 2019
-
-
Pierre-Yves David authored
Apparently, since the blackgnarok, we divergence from the expected formatting. Formatted using:: grey.py -S $(hg files 'set:**.py - mercurial/thirdparty/** - "contrib/python-zstandard/**" - hgext/fsmonitor/pywatchman/** - contrib/grey.py') # skip-blame mass-reformatting only # no-check-commit reformats foo_bar functions
-
- Oct 06, 2019
-
-
Augie Fackler authored
These used to be marked with no-op parens, but black removes those now and this is more explicit. # skip-blame: fallout from mass reformatting Differential Revision: https://phab.mercurial-scm.org/D6996
-
Augie Fackler authored
This is using my patch to black (https://github.com/psf/black/pull/826) so we don't un-wrap collection literals. Done with: hg files 'set:**.py - mercurial/thirdparty/** - "contrib/python-zstandard/**"' | xargs black -S # skip-blame mass-reformatting only # no-check-commit reformats foo_bar functions Differential Revision: https://phab.mercurial-scm.org/D6971
-
- Apr 26, 2019
-
-
Sietse Brouwer authored
Differential Revision: https://phab.mercurial-scm.org/D6329
-
- May 03, 2019
-
-
Sietse Brouwer authored
The new logic renders the commands belonging to each category in turn. Commands with an unregistered category are at risk of getting skipped because their category is not in the list. By comparing the list of all commands to a log of processed commands, we can detect commands with unregistered categories and fail with an error message. Differential Revision: https://phab.mercurial-scm.org/D6327
-
- Apr 26, 2019
-
-
Sietse Brouwer authored
Make Mercurial's man page and HTML help group commands by category, and present the categories in a helpful order. `hg help` already does this; this patch uses the same metadata. This patch uses the same header level for command categories and for commands. A subsequent patch will push the command headers down one level. Differential Revision: https://phab.mercurial-scm.org/D6326
-
- Apr 25, 2019
-
-
Sietse Brouwer authored
Differential Revision: https://phab.mercurial-scm.org/D6325
-
- Apr 04, 2019
-
-
Philippe Pepiot authored
-
Philippe Pepiot authored
-
Philippe Pepiot authored
Use "?=", otherwise the variable cannot be set from environment.
-
- Mar 03, 2019
-
-
Gregory Szorc authored
Currently, various processes for packaging Mercurial state to manually invoke `make -C doc` in order to generate the documentation. This Makefile merely invokes `gendoc.py` and `runrst` to produce man pages and HTML pages. Not all environments may have the ability to easily run Makefiles. Windows is notably in this set. This commit ports the man page and HTML generation logic from doc/Makefile to setup.py. We introduce a new build_doc command which generates documentation by calling gendoc.py and runrst. The documentation can now be built via pure Python by running `python setup.py build_doc`. We don't implement dependency tracking because IMO it is more effort than it is worth. We could potentially remove the duplicated functionality in doc/Makefile. But I'm not sure what all is depending on it. So I plan to keep it around. # no-check-commit because forced foo_bar function names Differential Revision: https://phab.mercurial-scm.org/D6063
-
- Feb 04, 2019
-
-
Gregory Szorc authored
This avoids a SyntaxWarning on Python 3.8 due to invalid \ escape. Differential Revision: https://phab.mercurial-scm.org/D5843
-
- Jan 24, 2019
-
-
Pulkit Goyal authored
# skip-blame because just b'' prefixes Differential Revision: https://phab.mercurial-scm.org/D5670
-
- Dec 22, 2018
-
-
Matt Harbison authored
-
- Dec 20, 2018
-
-
Matt Harbison authored
-
- Dec 19, 2018
-
-
Matt Harbison authored
The exception is printed as str because I'm too lazy to convert it and the pieces.
-
Matt Harbison authored
This is mostly b'' prefixing, with some cargoculting of help.py to get around `textwrap.dedent()` and __doc__ string requirements.
-
- Oct 12, 2018
-
-
Rodrigo Damazio Bovendorp authored
Differential Revision: https://phab.mercurial-scm.org/D5068
-
Rodrigo Damazio Bovendorp authored
Differential Revision: https://phab.mercurial-scm.org/D5066
-
- Oct 13, 2018
-
-
Rodrigo Damazio Bovendorp authored
Differential Revision: https://phab.mercurial-scm.org/D5065
-
- Sep 06, 2018
-
-
Yuya Nishihara authored
-
- Oct 10, 2017
-
-
muxator authored
This and the following commits try to add the necessary quoting in the build scripts to make the process more robust. The target for now is rendering "make deb" successful even when the base directory contains spaces (eg. "/opt/mercu rial"). The build process should succeed without scattering files in spurious directories (eg.: "/opt/mercu/usr/bin/hg").
-
- May 28, 2017
-
-
durin42 authored
-
- May 13, 2017
-
-
Yuya Nishihara authored
Otherwise some messages wouldn't be translated depending on when the util was loaded.
-
- Oct 22, 2016
-
-
Yuya Nishihara authored
This allows us to write doctests depending on a ui object, but not on global configs. ui.load() is a class method so we can do wsgiui.load(). All ui() calls but for doctests are replaced with ui.load(). Some of them could be changed to not load configs later.
-
- Oct 07, 2016
-
-
Augie Fackler authored
These don't exist in Python 3, and this ends up looking a little more explicit to Martijn and me anyway.
-
- May 14, 2016
-
-
Yuya Nishihara authored
-
- Jun 20, 2016
-
-
Katsunori FUJIWARA authored
Before this patch, "missing _() in ui message" rule overlooks translatable message, which starts with other than alphabet. To detect "missing _() in ui message" more exactly, this patch improves the regexp with assumptions below. - sequence consisting of below might precede "translatable message" in same string token - formatting string, which starts with '%' - escaped character, which starts with 'b' (as replacement of '\\'), or - characters other than '%', 'b' and 'x' (as replacement of alphabet) - any string tokens might precede a string token, which contains "translatable message" This patch builds an input file, which is used to examine "missing _() in ui message" detection, before '"$check_code" stringjoin.py' in test-contrib-check-code.t, because this reduces amount of change churn in subsequent patch. This patch also applies "()" instead of "_()" on messages below to hide false-positives: - messages for ui.debug() or debug commands/tools - contrib/debugshell.py - hgext/win32mbcs.py (ui.write() is used, though) - mercurial/commands.py - _debugchangegroup - debugindex - debuglocks - debugrevlog - debugrevspec - debugtemplate - untranslatable messages - doc/gendoc.py (ReST specific text) - hgext/hgk.py (permission string) - hgext/keyword.py (text written into configuration file) - mercurial/cmdutil.py (formatting strings for JSON)
-
- May 16, 2016
-
-
timeless authored
next(..) was introduced in py2.6 and .next() is not available in py3 https://docs.python.org/2/library/functions.html#next
-
- May 12, 2016
-
-
Pulkit Goyal authored
-
Pulkit Goyal authored
-
Pulkit Goyal authored
In python3 raise error, message has been changed to raise error(message) In additional to that nodes.SkipNode is changed to nodes.SkipNode() so that it creates an instance directly.
-
- May 07, 2016
-
-
Sean Farley authored
This corrects a warning from lintian that we're shipping an executable without a man page. Since there is a doc string in the text, let's use that for the man page.
-
- Apr 16, 2016
-
-
Pulkit Goyal authored
-