Commit Graph

222 Commits

Author SHA1 Message Date
Adam Turner
55669f6cfc Specify encoding 2022-04-22 04:21:12 +01:00
Adam Turner
0db2817328 Add command runners 2022-04-16 21:12:18 +01:00
Adam Turner
1e443bdcb4 Move compile_catalog_plusjs to utils/ 2022-04-16 20:01:03 +01:00
Adam Turner
61d7b0b47c Replace jssplitter with JavaScript 2022-03-19 23:16:27 +00:00
Takeshi KOMIYA
2beeaf746f
Merge branch 'master' into fix-searchtools 2022-03-20 01:49:48 +09:00
Adam Turner
ac9c2b5571 Update splitQuery 2022-03-08 01:46:38 +00:00
Adam Turner
51c6642ec2 Remove redundant sphinx/utils/checks.py 2022-02-20 03:31:33 +00:00
Adam Turner
5775912455 Collapse single line docstrings 2022-02-20 03:13:45 +00:00
Adam Turner
6bb7b891a1 Remove copyright and licence fields 2022-02-20 03:06:23 +00:00
Adam Turner
5694e0ce60 Fix module docstring indentation 2022-02-20 00:35:13 +00:00
Adam Turner
4f5a3269a6 Fix module docstring first line 2022-02-20 00:11:08 +00:00
Adam Turner
6b8bccec59 Remove module titles in docstrings 2022-02-19 23:17:29 +00:00
Daniel Eades
6697ed62ed address some unused loop control variables (B007) 2022-01-12 20:19:18 +00:00
Eisuke Kawashima
652ebf1bf5
Fix typo 2021-07-08 08:16:22 +09:00
Takeshi KOMIYA
56aea3b714 doclinter: Allow anonymous hyperlink target having long URL 2021-07-06 00:52:11 +09:00
Takeshi KOMIYA
e0500f7354 doc: Fix docslint misunderstanding scope of code-blocks 2021-06-06 13:24:06 +09:00
Takeshi KOMIYA
08c65d4de2 i18n: Pull translations via GitHub Actions automatically 2021-05-09 18:20:41 +09:00
Takeshi KOMIYA
effedafabe i18n: Push translations via GitHub Actions automatically 2021-05-09 17:15:36 +09:00
Takeshi KOMIYA
a8f7e4f563 doc: Update branch name in release-checklist 2021-01-08 01:25:24 +09:00
Takeshi KOMIYA
b3f8bd1e3c doc: Quote URLs in release checklist
To improve the install process, the commands on the checklist is updated
to allow to copy & paste it to console.
2021-01-04 21:12:27 +09:00
Takeshi KOMIYA
68cc0f7e94
Merge pull request #8408 from francoisfreitag/isort
Sort imports with isort
2020-11-12 02:05:13 +09:00
François Freitag
0949735210
Sort imports with isort
Keep imports alphabetically sorted and their order homogeneous across
Python source files.

The isort project has more feature and is more active than the
flake8-import-order plugin.

Most issues caught were simply import ordering from the same module.
Where imports were purposefully placed out of order, tag with
isort:skip.
2020-11-11 13:19:05 +01:00
Takeshi KOMIYA
658f737970 Check GitHub Actions before packaging 2020-11-05 02:17:54 +09:00
Takeshi KOMIYA
6cf1301c9e Remove pylint task
At present, pylint has no longer been used in this project. This
removes the tasks and files for pylint from repository.
2020-08-10 13:20:06 +09:00
Takeshi KOMIYA
0c4edbdb38 doclinter: Allow a very long literal string 2020-07-24 23:09:56 +09:00
Tetsuo Koyama
ae7c4cc3b8 fix typo 2020-07-19 00:43:11 +00:00
Takeshi KOMIYA
7167b689b9 Do "twine check" on CI process 2020-06-14 16:06:25 +09:00
Takeshi KOMIYA
c84f7bfd57 Merge branch '2.x' into 3.x 2020-03-01 02:13:36 +09:00
Takeshi KOMIYA
2a3dec8866 Add a procedure to update docker image 2020-02-24 12:21:38 +09:00
Takeshi KOMIYA
ffd980a1b7 Merge branch 'clean_dists_on_make_clean' into 2.4.x 2020-02-23 18:59:00 +09:00
Takeshi KOMIYA
2bac500eaa Merge branch 'update_release_checklist' into 2.4.x 2020-02-23 18:58:27 +09:00
Takeshi KOMIYA
27dc911650
Merge pull request #7204 from tk0miya/clean_dists_on_make_clean
Makefile: clean dists directory on "make clean"
2020-02-23 16:51:35 +09:00
Takeshi KOMIYA
4f0e83306e
Merge pull request #7203 from tk0miya/update_release_checklist
release-checklist: An update of doc-translations is no longer needed
2020-02-23 16:51:27 +09:00
Takeshi KOMIYA
5572eb7b9e Makefile: clean dists directory on "make clean" 2020-02-23 16:36:38 +09:00
Takeshi KOMIYA
2ecf5f4651 release-checklist: An update of doc-translations is no longer needed 2020-02-23 16:33:31 +09:00
Takeshi KOMIYA
d98b2f05a3 utils/bump_version: Remove empty sections from CHANGES automatically 2020-02-23 15:57:51 +09:00
Jon Dufresne
de21c2bf10 Correct str/bytes mixup in utils/jssplitter_generator.py
The file is opened in text mode, so it .wraite() takes str not bytes.
2019-08-17 09:42:16 -07:00
Takeshi KOMIYA
d6063ff35b doc: Fold lines by 80 columns 2019-05-30 01:07:05 +09:00
Takeshi KOMIYA
9b2423c5bb doclinter: restrict by 90 columns 2019-05-26 10:53:53 +09:00
Takeshi KOMIYA
439f329466 doclinter: Fix files are ignored. 2019-05-26 10:53:52 +09:00
Takeshi KOMIYA
c4b20a82ea doclinter: Ignore large code-block and long interpreted text 2019-05-26 10:53:52 +09:00
Takeshi KOMIYA
5d2c8e6eb7 Add utils/doclinter.py; a documenter linter for Sphinx 2019-05-12 17:57:25 +09:00
Jon Dufresne
22afc77c48 Python-3-only clean ups discovered by pyupgrade
https://github.com/asottile/pyupgrade

> A tool to automatically upgrade syntax for newer versions of the
> language.

- Drop u str prefix
- Drop base object inheritance
- Drop args to super()
- Use set literals
- Use dict comprehension
- Use set comprehension
2019-03-19 01:09:48 +09:00
Takeshi KOMIYA
6d02bdda13 Do "twine check" before uploading package 2019-03-10 18:58:02 +09:00
Takeshi KOMIYA
76e9f57c2e Merge branch '1.8' 2019-01-02 16:16:25 +09:00
Takeshi KOMIYA
1b1ebd2c75 A happy new year! 2019-01-02 16:00:30 +09:00
Takeshi KOMIYA
8ea3f7fad9
Merge pull request #5509 from stephenfin/remove-future-imports
Remove future imports
2018-12-17 20:32:39 +09:00
Stephen Finucane
5a9033e5aa Specifically request Python 3
If Sphinx is Python 3-only, Sphinx's tooling should be Python 3-only
too.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-12-17 09:46:18 +00:00
Stephen Finucane
d345d0f8c1 py3: Remove (most) __future__ imports
There were two used:

- print_function
- absolute_import

Both of these are mandatory in Python 3.0 onwards [1] and can therefore
be removed...mostly. Unfortunately, mypy is still running in Python 2.7
mode, meaning we need the 'print_function' future wherever we're calling
'print' with the 'file' argument. There's also a single
'absolute_import' future that must be retained as its removal breaks a
test for as-yet unknown reasons.  TODOs are added to resolve both issues
in the future.

[1] https://docs.python.org/3/library/__future__.html

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-12-17 09:46:15 +00:00
Jon Dufresne
bade33c7e4 Remove unnecessary encoding cookie from Python source files
In Python 3, the default encoding of source files is utf-8. The encoding
cookie is now unnecessary and redundant so remove it. For more details,
see the docs:

https://docs.python.org/3/howto/unicode.html#the-string-type

> The default encoding for Python source code is UTF-8, so you can
> simply include a Unicode character in a string literal ...

Includes a fix for the flake8 header checks to stop expecting an
encoding cookie.
2018-12-16 12:22:12 -08:00
Takeshi KOMIYA
ea1d2d06f8
Merge pull request #5803 from jdufresne/encoding-utf8
Avoid respecifying default encoding for .encode()/.decode() calls
2018-12-16 20:01:43 +09:00
Jon Dufresne
5bf25eb445 Avoid respecifying default encoding for .encode()/.decode() calls
In Python 3, both .encode() and .decode() default the encoding to
'utf-8'. See the docs:

https://docs.python.org/3/library/stdtypes.html#str.encode
https://docs.python.org/3/library/stdtypes.html#bytes.decode

Simplify and shorten the code by using the default instead of
respecifying it.
2018-12-15 17:19:56 -08:00
Jon Dufresne
1f4fcd656b Remove use of six.unichr()
Use Python 3 chr() instead.
2018-12-15 08:15:56 -08:00
Jon Dufresne
490e4aed41 Remove unnecessary object from class definitions
In Python 3, all classes are new-style classes. The object in the
definition is redundant and unnecessary.
2018-09-11 07:07:01 -07:00
Takeshi KOMIYA
bc19cf72c9 Merge branch '1.7' 2018-05-14 01:04:45 +09:00
Takeshi KOMIYA
c9890cb653 Update release-checklist 2018-05-11 22:28:04 +09:00
shimizukawa
ab101744f2 Use twine instead of 'setup.py upload'. There are security reason ( https://packaging.python.org/tutorials/distributing-packages/#uploading-your-project-to-pypi ) and metadata reason (refs #4936 ). 2018-05-09 11:31:41 +09:00
Jon Dufresne
365c93f227 Update all pypi.python.org URLs to pypi.org
For details on the new PyPI, see the blog post:

https://pythoninsider.blogspot.ca/2018/04/new-pypi-launched-legacy-pypi-shutting.html
2018-04-18 19:51:48 -07:00
Takeshi KOMIYA
8bc3691966
Merge pull request #4638 from tk0miya/fix_markup
doc: Fix markup
2018-02-18 16:10:08 +09:00
Takeshi KOMIYA
e9003ac07e doc: Fix markup 2018-02-18 12:40:46 +09:00
Takeshi KOMIYA
f8bb40ab30 Merge branch '1.7' 2018-02-18 12:39:07 +09:00
Takeshi KOMIYA
a721b32d51 docs: Use literal for commands 2018-02-16 21:40:07 +09:00
Takeshi KOMIYA
4b0cff0253 docs: protect and unprotect the stable branch on releasing 2018-02-12 22:54:38 +09:00
Takeshi KOMIYA
7a92e3e409 Call git fetch before checking status 2018-02-07 10:49:46 +09:00
Takeshi KOMIYA
94eae2c4f9 Add procedures for beta and final releases 2018-02-06 23:19:32 +09:00
Takeshi KOMIYA
35f05bdc7e Update release checklist (again) 2018-02-03 02:13:02 +09:00
Takeshi KOMIYA
60f2e13f49
Merge pull request #4513 from tk0miya/update_release_checklist
Update release checklist
2018-02-03 02:09:50 +09:00
Takeshi KOMIYA
ab274e920b Update release checklist 2018-01-29 00:24:30 +09:00
Takeshi KOMIYA
9f5c676322 Use flake8-import-order 2018-01-28 01:52:16 +09:00
Takeshi KOMIYA
bcb1bd914d package: update bump_version.py 2018-01-15 22:24:52 +09:00
Takeshi KOMIYA
5562e76585 A happy new year! 2018-01-01 01:10:10 +09:00
Takeshi KOMIYA
f1f6ca8cc9 Merge branch 'happy_new_year' into master 2018-01-01 01:09:17 +09:00
Takeshi KOMIYA
2426cedb8b A happy new year! 2018-01-01 01:06:58 +09:00
Takeshi KOMIYA
e3baf213f5 Merge branch 'stable' 2017-10-23 23:04:32 +09:00
Takeshi KOMIYA
47c869c89a Fix flake8 and style-check violations 2017-10-23 23:01:18 +09:00
Takeshi KOMIYA
5de42c4c50 Merge pull request #4121 from stephenfin/remove-check-indent
utils: Remove the 'reindent' tool
2017-10-21 18:17:47 +09:00
Stephen Finucane
160e27e20f utils: Remove 'check_sources'
There are still a couple of checks here but all of them can be removed
now:

- Check if using valid Python syntax
- Check if line length too long
- Check if using 'x == None/True/False'
- Check if using old HTML 3 tags

The first three are already handled by default by the 'flake8' tool. The
last one isn't replaced by anything, but it really isn't worth worrying
about now because the tags it checks for have been dead for a really
long time and would not be used by anyone writing HTML in the last 10
years. Combined, it means we can remove the entire file.

The 'style-check' target is updated to simply alias 'flake8'. It can be
removed in a future release. This allows us to stop using this target in
the Travis jobs, seeing as we already run flake8.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2017-10-05 17:17:27 +01:00
Stephen Finucane
f5c0d64658 utils: Move "header check" to a flake8 plugin
If we want to check style, we run 'tox -e flake8': it shouldn't be
necessary to run some obscure 'make' command too. Make this possible by
moving the sole useful test from the target of this make command to a
flake8 plugin.

This includes a fix for a header that was previously excluded from
checks, but is now included.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2017-10-05 17:17:27 +01:00
Stephen Finucane
64b4d7c686 utils: Use better variable names in check_fileheader
We're going to be doing some surgery on this function, so first clean it
up before we do anything else.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2017-10-05 17:17:27 +01:00
Stephen Finucane
b90e58809f utils: Remove the 'reindent' tool
Nobody seems to be using this, probably because of the 'flake8' target,
and it hasn't been touched, some Python/flake8 updates aside in years.
Just remove it.

The Make target is not removed to both give us time to warn users that
the target is gone and, more importantly, to prevent merge conflicts
with other patches being submitted at the same time.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2017-10-05 17:13:59 +01:00
Daniel Hahler
5359bb8ba5 Fix DeprecationWarning for r'…(?u)'
Fixes

> DeprecationWarning: Flags not at the start of the expression …
2017-08-18 11:53:37 +02:00
Takeshi KOMIYA
8683823536 pycode: Replace pgen2 by own parser 2017-07-26 20:51:58 +09:00
Takeshi KOMIYA
ca6a1edd2f Merge branch 'stable' 2017-05-26 00:15:00 +09:00
Takeshi KOMIYA
068fd115d6 Add dependencies category to CHANGES template 2017-05-26 00:10:56 +09:00
Takeshi KOMIYA
e7ffa63463 Merge branch 'stable' 2017-05-16 23:53:46 +09:00
Takeshi KOMIYA
e322fa8480 Update message catalogs 2017-05-16 22:21:44 +09:00
Takeshi KOMIYA
7cca0b456e Merge pull request #3668 from adamjstewart/fixes/apidoc-main-argv
Don't ignore first argument passed to sphinx.apidoc.main
2017-05-14 01:11:49 +09:00
Adam J. Stewart
326ddd10d7 Fix failing unit tests 2017-05-11 12:53:15 -05:00
Adam J. Stewart
392e6ecd6f Update more files that hardcode sys.argv 2017-05-09 14:43:19 -05:00
Takeshi KOMIYA
4de4fd060a bump_version.py: Fix generate non-beta version number on beta release 2017-04-30 00:40:33 +09:00
shimizukawa
ac5e76f598 extract messages 2017-04-29 01:02:00 +09:00
Takeshi KOMIYA
8f9dd64992 Merge branch 'stable' 2017-03-26 11:52:15 +09:00
Takeshi KOMIYA
c57e47e042 Year++ 2017-03-26 11:49:34 +09:00
Takeshi KOMIYA
e1da72b59c Reduce DeprecationWarnings for regexp 2017-02-17 02:01:04 +09:00
Takeshi KOMIYA
fd2b3ec529 Merge branch 'stable' 2017-01-22 17:36:03 +09:00
Takeshi KOMIYA
2c91a52418 Update release-checklist 2017-01-22 17:30:07 +09:00
jfbu
cf966d4a97 Merge branch 'stable' 2017-01-21 15:21:33 +01:00
Takeshi KOMIYA
a7b4379c41 Rename bump_version.py 2017-01-21 20:16:59 +09:00
Takeshi KOMIYA
3f17bebecb Add bump_version.py 2017-01-21 19:45:35 +09:00
Takeshi KOMIYA
38d6c34f35 Merge branch 'stable' 2017-01-12 13:03:53 +09:00