There was an error while loading. Please reload this page.
1 parent 9ce34f2 commit 876c7cdCopy full SHA for 876c7cd
1 file changed
docs/parameter-types.rst
@@ -33,8 +33,8 @@ Example:
33
import enum
34
35
class HashType(enum.Enum):
36
- MD5 = 'MD5'
37
- SHA1 = 'SHA1'
+ MD5 = enum.auto()
+ SHA1 = enum.auto()
38
39
@click.command()
40
@click.option('--hash-type',
@@ -54,8 +54,8 @@ What it looks like:
54
println()
55
invoke(digest, args=['--help'])
56
57
-Since version 8.2.0 any iterable may be passed to :class:`Choice`, here
58
-an ``Enum`` is used which will result in all enum values to be valid
+Any iterable may be passed to :class:`Choice`. Here
+an ``Enum`` is used which will result in all enum names to be valid
59
choices.
60
61
Choices work with options that have ``multiple=True``. If a ``default``
0 commit comments