Skip to content

Commit 34e0591

Browse files
committed
Add to What's New, combine NEWS files, update reference, use sentence case
https://devguide.python.org/documentation/style-guide/\#capitalization
1 parent a2c0d53 commit 34e0591

File tree

5 files changed

+16
-9
lines changed

5 files changed

+16
-9
lines changed

Doc/library/cmdline.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ The following modules have a command-line interface.
2424
* :mod:`!idlelib`
2525
* :ref:`inspect <inspect-module-cli>`
2626
* :ref:`json <json-commandline>`
27-
* :mod:`mimetypes`
27+
* :ref:`mimetypes <mimetypes-cli>`
2828
* :mod:`pdb`
2929
* :mod:`pickle`
3030
* :ref:`pickletools <pickletools-cli>`

Doc/library/mimetypes.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ An example usage of the module::
191191

192192
.. _mimetypes-objects:
193193

194-
MimeTypes Objects
194+
MimeTypes objects
195195
-----------------
196196

197197
The :class:`MimeTypes` class may be useful for applications which may want more
@@ -309,9 +309,9 @@ than one MIME-type database; it provides an interface similar to the one of the
309309
official MIME types, otherwise to the non-standard ones.
310310

311311

312-
.. mimetypes-cli:
312+
.. _mimetypes-cli:
313313

314-
Command-Line Usage
314+
Command-line usage
315315
------------------
316316

317317
The :mod:`!mimetypes` module can be executed as a script from the command line.
@@ -350,7 +350,7 @@ standard error stream and exits with the return code ``1``.
350350

351351
.. mimetypes-cli-example:
352352
353-
Command-Line Example
353+
Command-line example
354354
--------------------
355355

356356
Here are some examples of typical usage of the :mod:`!mimetypes` command-line

Doc/whatsnew/3.14.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -641,6 +641,13 @@ json
641641
mimetypes
642642
---------
643643

644+
* Document the command-line for :mod:`mimetypes`.
645+
It now exits with ``1`` on failure instead of ``0``
646+
and ``2`` on incorrect command-line parameters instead of ``1``.
647+
Also, errors are printed to stderr instead of stdout and their text is made
648+
tighter.
649+
(Contributed by Oleg Iarygin and Hugo van Kemenade in :gh:`93096`.)
650+
644651
* Add MS and :rfc:`8081` MIME types for fonts:
645652

646653
* Embedded OpenType: ``application/vnd.ms-fontobject``

Misc/NEWS.d/next/Documentation/2022-05-23-11-53-24.gh-issue-93096.TIuIhx.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
Command-line :mod:`mimetypes` now exits with ``1`` on failure instead of ``0``
2-
and ``2`` on incorrect command line parameters instead of ``1``.
1+
Document the command-line for :mod:`mimetypes`.
2+
It now exits with ``1`` on failure instead of ``0``
3+
and ``2`` on incorrect command-line parameters instead of ``1``.
34
Also, errors are printed to stderr instead of stdout and their text is made
4-
tighter. Patch by Oleg Iarygin.
5+
tighter. Patch by Oleg Iarygin and Hugo van Kemenade.

0 commit comments

Comments
 (0)