Remove $
, >>>
and other prompt prefixes when code copied from the… (#3884)
Adding configurations for sphinx-copybutton in conf.py https://sphinx-copybutton.readthedocs.io/en/latest/use.html#using-regexp-prompt-identifiers
This commit is contained in:
parent
27c05e1e24
commit
3a2d76c7bc
@ -210,6 +210,13 @@ def make_pypi_svg(version: str) -> None:
|
||||
|
||||
autodoc_member_order = "bysource"
|
||||
|
||||
# -- sphinx-copybutton configuration ----------------------------------------
|
||||
copybutton_prompt_text = (
|
||||
r">>> |\.\.\. |> |\$ |\# | In \[\d*\]: | {2,5}\.\.\.: | {5,8}: "
|
||||
)
|
||||
copybutton_prompt_is_regexp = True
|
||||
copybutton_remove_prompts = True
|
||||
|
||||
# -- Options for intersphinx extension ---------------------------------------
|
||||
|
||||
# Example configuration for intersphinx: refer to the Python standard library.
|
||||
|
Loading…
Reference in New Issue
Block a user