Skip to content

Move substitutions from common_links.rst to doc_guide.rst - #2272

Merged
namurphy merged 8 commits into
PlasmaPy:mainfrom
namurphy:move-common-links-stuff-to-doc-guide
Aug 8, 2023
Merged

namurphy merged 8 commits into
PlasmaPy:mainfrom
namurphy:move-common-links-stuff-to-doc-guide

Conversation

@namurphy

@namurphy namurphy commented Aug 4, 2023

Copy link
Copy Markdown
Member

We use docs/common_links.rst as a place to define links and substitutions across the documentation. Essentially the content in common_links.rst gets added to the epilogue of each .rst file and docstring. This has the potential to slow down documentation builds.

This PR is an attempt to consolidate some of the shortcuts into the documentation guide, since that's the main place that they get used.

Unfortunately we don't have a good or consistent way to benchmark documentation builds yet, so I don't know for sure that it'll speed things up noticeably. At the very least, it'll keep these definitions in a place that's closer to where they get used.

@github-actions

github-actions Bot commented Aug 4, 2023

Copy link
Copy Markdown

Thank you for submitting a pull request (PR) to PlasmaPy! ✨ The future of the project depends on contributors like you, so we deeply appreciate it! 🌱

Our contributor guide has information on:

The bottom of this page shows several checks that are run for every PR. Don't worry if something broke! We break stuff all the time. 😺 Click on "Details" to learn why a check didn't pass. Please also feel free to ask for help. We do that all the time as well. 🌸 You can find us in our chat room or weekly community meeting & office hours. Here are some tips:

  • Try fixing CI / Python 3.11 test failures first.
  • Most pre-commit.ci - pr failures can be automagically fixed by commenting pre-commit.ci autofix below, followed by a git pull to bring the changes back to your computer.
  • If pre-commit.ci - pr says that a function is too long or complex, try breaking up that function into multiple short functions that each do one thing. See also these tips on writing clean scientific software.
  • If the CI / Documentation check ends with a cryptic error message, check out our documentation troubleshooting guide.
  • For a documentation preview, click on Details next to docs/readthedocs.org:plasmapy.

If this PR is marked as ready for review, someone should stop by to provide a code review and offer suggestions soon. ✅ If you don't get a review within a few days, please feel free to send us a reminder.

Please also use SI units within PlasmaPy, except when there is strong justification otherwise or in some examples.

We thank you once again!

@github-actions github-actions Bot added docs PlasmaPy Docs at http://docs.plasmapy.org contributor guide labels Aug 4, 2023
@codecov

codecov Bot commented Aug 4, 2023 •

Copy link
Copy Markdown

Codecov Report

Patch and project coverage have no change.

Comparison is base (7ce5579) 98.37% compared to head (3fc3135) 98.37%.
Report is 3 commits behind head on main.

❗ Current head 3fc3135 differs from pull request most recent head 6130fd6. Consider uploading reports for the commit 6130fd6 to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2272   +/-   ##
=======================================
  Coverage   98.37%   98.37%           
=======================================
  Files          98       98           
  Lines        8533     8533           
=======================================
  Hits         8394     8394           
  Misses        139      139           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@github-actions github-actions Bot added CI Related to continuous integration GitHub Actions A continuous integration platform for automating tests and other tasks (see .github/ directory) labels Aug 4, 2023
@namurphy

namurphy commented Aug 4, 2023

Copy link
Copy Markdown
Member Author

Next step:

Comment thread docs/changelog/0.7.0.rst
add and cite references to PlasmaPy's global bibliography BibTeX_ file,
:file:`docs/bibliography.bib`. (`#1263 <https://github.com/plasmapy/plasmapy/pull/1263>`__)
- Added sphinxcontrib-bibtex_ as a Sphinx_ extension to enable references
- Added ``sphinxcontrib-bibtex`` as a Sphinx_ extension to enable references

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of these substitutions were used only in the documentation guide and a changelog entry. It's not important to have these links in the changelog entries, so I'm converting them to in-line code-snippets.

Comment on lines +1421 to +1433
.. ----------------------
.. Nested inline literals
.. ----------------------

.. A workaround for nested inline literals so that the filename will get
formatted like a file but will be a link. In the text, these get used
with the syntax for a substitution followed by an underscore to
indicate that it's for a link: |docs/_static|_

.. For these workarounds, if the replacement is something in single back
ticks (e.g., `xarray`), then it should also be added to
nitpick_ignore_regex in docs/conf.py so that it doesn't get counted
as an error in a nitpicky doc build (e.g., tox -e doc_build_nitpicky).

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was copied verbatim from docs/common_links.rst so it's already been reviewed in a previous pull request.

Comment thread changelog/2272.doc.rst Resolved
Comment thread .github/workflows/testing.yml Resolved
Comment thread changelog/2272.doc.rst Resolved
@github-actions github-actions Bot removed CI Related to continuous integration GitHub Actions A continuous integration platform for automating tests and other tasks (see .github/ directory) labels Aug 8, 2023
@namurphy

namurphy commented Aug 8, 2023

Copy link
Copy Markdown
Member Author

Merging this to avoid merge conflicts in #2281.

@namurphy
namurphy merged commit 7333bde into PlasmaPy:main Aug 8, 2023
@namurphy
namurphy deleted the move-common-links-stuff-to-doc-guide branch August 8, 2023 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor guide docs PlasmaPy Docs at http://docs.plasmapy.org

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant