File tree Expand file tree Collapse file tree 3 files changed +13
-2
lines changed
python-project-template/{% if include_docs %}docs{% endif %} Expand file tree Collapse file tree 3 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,16 @@ extensions.append("autoapi.extension")
3131extensions.append("nbsphinx")
3232{% - endif %}
3333
34+ # -- sphinx-copybutton configuration ----------------------------------------
35+ extensions.append("sphinx_copybutton")
36+ ## sets up the expected prompt text from console blocks, and excludes it from
37+ ## the text that goes into the clipboard.
38+ copybutton_exclude = ".linenos, .gp"
39+ copybutton_prompt_text = ">> "
40+
41+ ## lets us suppress the copy button on select code blocks.
42+ copybutton_selector = "div:not(.no-copybutton) > div.highlight > pre"
43+
3444templates_path = []
3545exclude_patterns = ["_build", "**.ipynb_checkpoints"]
3646
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ virtual environment. LINCC-Frameworks engineers primarily use `conda` to manage
1313environments. If you have conda installed locally, you can run the following to
1414create and activate a new environment.
1515
16- .. code-block:: bash
16+ .. code-block:: console
1717
1818 >> conda create env -n <env _name > python=3.10
1919 >> conda activate <env _name >
@@ -22,7 +22,7 @@ create and activate a new environment.
2222Once you have created a new environment, you can install this project for local
2323development using the following commands:
2424
25- .. code-block:: bash
25+ .. code-block:: console
2626
2727 >> pip install -e .'[dev]'
2828 >> pre-commit install
Original file line number Diff line number Diff line change 11sphinx
22sphinx-rtd-theme
33sphinx-autoapi
4+ sphinx-copybutton
45{% - if include_notebooks %}
56nbsphinx
67ipython
You can’t perform that action at this time.
0 commit comments