From 54f1063357cb3096d6ec9985fbba2c670ef6297f Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Sun, 20 Sep 2020 19:14:35 +0200 Subject: [PATCH 1/7] add manim_directive module to reference manual --- docs/source/manim_directive.py | 3 +- docs/source/reference.rst | 140 ++++++++++++++++----------------- 2 files changed, 72 insertions(+), 71 deletions(-) diff --git a/docs/source/manim_directive.py b/docs/source/manim_directive.py index aa731e13dd..cf92b4c0d4 100644 --- a/docs/source/manim_directive.py +++ b/docs/source/manim_directive.py @@ -72,7 +72,8 @@ def construct(self): class ManimDirective(Directive): - r"""The ``.. manim::`` directive. + r"""The manim directive, rendering videos while building + the documentation. See the module docstring for documentation. """ diff --git a/docs/source/reference.rst b/docs/source/reference.rst index 804869f38c..465ebead01 100644 --- a/docs/source/reference.rst +++ b/docs/source/reference.rst @@ -8,7 +8,6 @@ the :doc:`changelog`. .. warning:: The pages linked to here are currently a work in progress. -.. currentmodule:: manim ******************** Mathematical Objects @@ -17,32 +16,32 @@ Mathematical Objects .. autosummary:: :toctree: reference - ~mobject.changing - ~mobject.coordinate_systems - ~mobject.frame - ~mobject.functions - ~mobject.geometry - ~mobject.matrix - ~mobject.mobject - ~mobject.mobject_update_utils - ~mobject.number_line - ~mobject.numbers - ~mobject.probability - ~mobject.shape_matchers - ~mobject.three_d_shading_utils - ~mobject.three_d_utils - ~mobject.three_dimensions - ~mobject.value_tracker - ~mobject.vector_field - ~mobject.svg.brace - ~mobject.svg.code_mobject - ~mobject.svg.drawings - ~mobject.svg.svg_mobject - ~mobject.svg.tex_mobject - ~mobject.svg.text_mobject - ~mobject.types.image_mobject - ~mobject.types.point_cloud_mobject - ~mobject.types.vectorized_mobject + ~manim.mobject.changing + ~manim.mobject.coordinate_systems + ~manim.mobject.frame + ~manim.mobject.functions + ~manim.mobject.geometry + ~manim.mobject.matrix + ~manim.mobject.mobject + ~manim.mobject.mobject_update_utils + ~manim.mobject.number_line + ~manim.mobject.numbers + ~manim.mobject.probability + ~manim.mobject.shape_matchers + ~manim.mobject.three_d_shading_utils + ~manim.mobject.three_d_utils + ~manim.mobject.three_dimensions + ~manim.mobject.value_tracker + ~manim.mobject.vector_field + ~manim.mobject.svg.brace + ~manim.mobject.svg.code_mobject + ~manim.mobject.svg.drawings + ~manim.mobject.svg.svg_mobject + ~manim.mobject.svg.tex_mobject + ~manim.mobject.svg.text_mobject + ~manim.mobject.types.image_mobject + ~manim.mobject.types.point_cloud_mobject + ~manim.mobject.types.vectorized_mobject ****** @@ -52,15 +51,15 @@ Scenes .. autosummary:: :toctree: reference - ~scene.graph_scene - ~scene.moving_camera_scene - ~scene.reconfigurable_scene - ~scene.sample_space_scene - ~scene.scene - ~scene.scene_file_writer - ~scene.three_d_scene - ~scene.vector_space_scene - ~scene.zoomed_scene + ~manim.scene.graph_scene + ~manim.scene.moving_camera_scene + ~manim.scene.reconfigurable_scene + ~manim.scene.sample_space_scene + ~manim.scene.scene + ~manim.scene.scene_file_writer + ~manim.scene.three_d_scene + ~manim.scene.vector_space_scene + ~manim.scene.zoomed_scene ********** @@ -70,18 +69,18 @@ Animations .. autosummary:: :toctree: reference - ~animation.animation - ~animation.composition - ~animation.creation - ~animation.fading - ~animation.growing - ~animation.indication - ~animation.movement - ~animation.numbers - ~animation.rotation - ~animation.specialized - ~animation.transform - ~animation.update + ~manim.animation.animation + ~manim.animation.composition + ~manim.animation.creation + ~manim.animation.fading + ~manim.animation.growing + ~manim.animation.indication + ~manim.animation.movement + ~manim.animation.numbers + ~manim.animation.rotation + ~manim.animation.specialized + ~manim.animation.transform + ~manim.animation.update ******* @@ -91,11 +90,11 @@ Cameras .. autosummary:: :toctree: reference - ~camera.camera - ~camera.mapping_camera - ~camera.moving_camera - ~camera.multi_camera - ~camera.three_d_camera + ~manim.camera.camera + ~manim.camera.mapping_camera + ~manim.camera.moving_camera + ~manim.camera.multi_camera + ~manim.camera.three_d_camera ********* @@ -105,20 +104,20 @@ Utilities .. autosummary:: :toctree: reference - ~utils.bezier - ~utils.color - ~utils.config_ops - ~utils.hashing - ~utils.images - ~utils.iterables - ~utils.paths - ~utils.rate_functions - ~utils.simple_functions - ~utils.sounds - ~utils.space_ops - ~utils.strings - ~utils.tex - ~utils.tex_file_writing + ~manim.utils.bezier + ~manim.utils.color + ~manim.utils.config_ops + ~manim.utils.hashing + ~manim.utils.images + ~manim.utils.iterables + ~manim.utils.paths + ~manim.utils.rate_functions + ~manim.utils.simple_functions + ~manim.utils.sounds + ~manim.utils.space_ops + ~manim.utils.strings + ~manim.utils.tex + ~manim.utils.tex_file_writing ************* @@ -128,9 +127,10 @@ Other modules .. autosummary:: :toctree: reference - _config - constants - container + ~manim._config + ~manim.constants + ~manim.container + manim_directive .. This is here so that sphinx doesn't complain about changelog.rst not being From ff5b1df0c0e31bde2d888ccec1673a74bcf22862 Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Sun, 20 Sep 2020 19:45:35 +0200 Subject: [PATCH 2/7] Revert "add manim_directive module to reference manual" This reverts commit 54f1063357cb3096d6ec9985fbba2c670ef6297f. --- docs/source/manim_directive.py | 3 +- docs/source/reference.rst | 140 ++++++++++++++++----------------- 2 files changed, 71 insertions(+), 72 deletions(-) diff --git a/docs/source/manim_directive.py b/docs/source/manim_directive.py index cf92b4c0d4..aa731e13dd 100644 --- a/docs/source/manim_directive.py +++ b/docs/source/manim_directive.py @@ -72,8 +72,7 @@ def construct(self): class ManimDirective(Directive): - r"""The manim directive, rendering videos while building - the documentation. + r"""The ``.. manim::`` directive. See the module docstring for documentation. """ diff --git a/docs/source/reference.rst b/docs/source/reference.rst index 465ebead01..804869f38c 100644 --- a/docs/source/reference.rst +++ b/docs/source/reference.rst @@ -8,6 +8,7 @@ the :doc:`changelog`. .. warning:: The pages linked to here are currently a work in progress. +.. currentmodule:: manim ******************** Mathematical Objects @@ -16,32 +17,32 @@ Mathematical Objects .. autosummary:: :toctree: reference - ~manim.mobject.changing - ~manim.mobject.coordinate_systems - ~manim.mobject.frame - ~manim.mobject.functions - ~manim.mobject.geometry - ~manim.mobject.matrix - ~manim.mobject.mobject - ~manim.mobject.mobject_update_utils - ~manim.mobject.number_line - ~manim.mobject.numbers - ~manim.mobject.probability - ~manim.mobject.shape_matchers - ~manim.mobject.three_d_shading_utils - ~manim.mobject.three_d_utils - ~manim.mobject.three_dimensions - ~manim.mobject.value_tracker - ~manim.mobject.vector_field - ~manim.mobject.svg.brace - ~manim.mobject.svg.code_mobject - ~manim.mobject.svg.drawings - ~manim.mobject.svg.svg_mobject - ~manim.mobject.svg.tex_mobject - ~manim.mobject.svg.text_mobject - ~manim.mobject.types.image_mobject - ~manim.mobject.types.point_cloud_mobject - ~manim.mobject.types.vectorized_mobject + ~mobject.changing + ~mobject.coordinate_systems + ~mobject.frame + ~mobject.functions + ~mobject.geometry + ~mobject.matrix + ~mobject.mobject + ~mobject.mobject_update_utils + ~mobject.number_line + ~mobject.numbers + ~mobject.probability + ~mobject.shape_matchers + ~mobject.three_d_shading_utils + ~mobject.three_d_utils + ~mobject.three_dimensions + ~mobject.value_tracker + ~mobject.vector_field + ~mobject.svg.brace + ~mobject.svg.code_mobject + ~mobject.svg.drawings + ~mobject.svg.svg_mobject + ~mobject.svg.tex_mobject + ~mobject.svg.text_mobject + ~mobject.types.image_mobject + ~mobject.types.point_cloud_mobject + ~mobject.types.vectorized_mobject ****** @@ -51,15 +52,15 @@ Scenes .. autosummary:: :toctree: reference - ~manim.scene.graph_scene - ~manim.scene.moving_camera_scene - ~manim.scene.reconfigurable_scene - ~manim.scene.sample_space_scene - ~manim.scene.scene - ~manim.scene.scene_file_writer - ~manim.scene.three_d_scene - ~manim.scene.vector_space_scene - ~manim.scene.zoomed_scene + ~scene.graph_scene + ~scene.moving_camera_scene + ~scene.reconfigurable_scene + ~scene.sample_space_scene + ~scene.scene + ~scene.scene_file_writer + ~scene.three_d_scene + ~scene.vector_space_scene + ~scene.zoomed_scene ********** @@ -69,18 +70,18 @@ Animations .. autosummary:: :toctree: reference - ~manim.animation.animation - ~manim.animation.composition - ~manim.animation.creation - ~manim.animation.fading - ~manim.animation.growing - ~manim.animation.indication - ~manim.animation.movement - ~manim.animation.numbers - ~manim.animation.rotation - ~manim.animation.specialized - ~manim.animation.transform - ~manim.animation.update + ~animation.animation + ~animation.composition + ~animation.creation + ~animation.fading + ~animation.growing + ~animation.indication + ~animation.movement + ~animation.numbers + ~animation.rotation + ~animation.specialized + ~animation.transform + ~animation.update ******* @@ -90,11 +91,11 @@ Cameras .. autosummary:: :toctree: reference - ~manim.camera.camera - ~manim.camera.mapping_camera - ~manim.camera.moving_camera - ~manim.camera.multi_camera - ~manim.camera.three_d_camera + ~camera.camera + ~camera.mapping_camera + ~camera.moving_camera + ~camera.multi_camera + ~camera.three_d_camera ********* @@ -104,20 +105,20 @@ Utilities .. autosummary:: :toctree: reference - ~manim.utils.bezier - ~manim.utils.color - ~manim.utils.config_ops - ~manim.utils.hashing - ~manim.utils.images - ~manim.utils.iterables - ~manim.utils.paths - ~manim.utils.rate_functions - ~manim.utils.simple_functions - ~manim.utils.sounds - ~manim.utils.space_ops - ~manim.utils.strings - ~manim.utils.tex - ~manim.utils.tex_file_writing + ~utils.bezier + ~utils.color + ~utils.config_ops + ~utils.hashing + ~utils.images + ~utils.iterables + ~utils.paths + ~utils.rate_functions + ~utils.simple_functions + ~utils.sounds + ~utils.space_ops + ~utils.strings + ~utils.tex + ~utils.tex_file_writing ************* @@ -127,10 +128,9 @@ Other modules .. autosummary:: :toctree: reference - ~manim._config - ~manim.constants - ~manim.container - manim_directive + _config + constants + container .. This is here so that sphinx doesn't complain about changelog.rst not being From fd9bfacf9f5d051bfbe57336cca816ab327d2562 Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Sun, 20 Sep 2020 19:49:27 +0200 Subject: [PATCH 3/7] contributing.md -> contributing.rst --- docs/source/{contributing.md => contributing.rst} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docs/source/{contributing.md => contributing.rst} (100%) diff --git a/docs/source/contributing.md b/docs/source/contributing.rst similarity index 100% rename from docs/source/contributing.md rename to docs/source/contributing.rst From 0fcaeb94d90ee31dd53c625e0a9b43cb71348266 Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Sun, 20 Sep 2020 21:51:10 +0200 Subject: [PATCH 4/7] reformat contributing.rst as restructuredText, try to simplify --- docs/source/contributing.rst | 257 +++++++++++++++++++---------------- 1 file changed, 143 insertions(+), 114 deletions(-) diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index 2d7a4d11e9..da2c4fe1bf 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -1,4 +1,6 @@ -# Contributing +############ +Contributing +############ Thank you for contributing to Manim! However you have decided to contribute or interact with the community, please always be civil and respect other members @@ -8,180 +10,207 @@ mathematics, pedagogy, computer animations, open-source, software development, and beyond. Manim accepts contributions of many kinds, detailed below. Many ways of contributing will involve writing, reading, testing, or -refactoring code. As our repository is a Fork of [Manim by -3b1b](https://github.com/3b1b/manim), contributing in this way can be a bit +refactoring code. As our repository is a Fork of `Manim by +3b1b `_, contributing in this way can be a bit confusing. Here is a short guide on how to do it. -1. Make a fork of this repository on Github. +Setup Manim with Version Control +================================ + +#. *Make a fork of this repository on Github.* You will need an account with Github. This will allow you to make pull requests (PR) to the ManimCommunity repo later on. -2. Clone your fork. - +#. *Clone your fork.* You can clone your Github fork by running: - ```sh - git clone - cd manim - ``` - GitHub will provide both a SSH (`git@github.com:/manim.git`) and - HTTPS (`https://github.com//manim.git`) URL for cloning the repo. + + .. code-block:: shell + + git clone + cd manim + + GitHub will provide both a SSH (``git@github.com:/manim.git``) and + HTTPS (``https://github.com//manim.git``) URL for cloning the repo. You can use whichever one you are setup for. - Note: Do not `git clone` the original ManimCommunity repository. You must - clone your own fork. After this step, there are three different - repositories to keep track of: the original ManimCommunity repo, your own - fork of it, and your local repository. + .. WARNING:: + + Do not ``git clone`` the original ManimCommunity repository. You must + clone your own fork. After this step, there are three different + repositories to keep track of: the original ManimCommunity repo, your own + fork of it, and your local repository. -3. Make `git` aware of the ManimCommunity repo. +#. Make ``git`` aware of the ManimCommunity repo. - ```sh - git remote add upstream https://github.com/ManimCommunity/manim.git - git fetch upstream - ``` + .. code-block:: shell - After these commands, your local repository can keep track of your fork - (referred to as 'origin') as well as the main ManimCommunity repository - (referred to as 'upstream'). + git remote add upstream https://github.com/ManimCommunity/manim.git + git fetch upstream -4. Choose the branch for your changes. + After these commands, your local repository can keep track of your fork + (referred to as 'origin') as well as the main ManimCommunity repository + (referred to as 'upstream'). +#. *Install manim.* + See the :doc:`installation instructions for developers ` for + details. + +You are now ready to work on manim! + + +Changing manim's Source Code +============================ + +#. *Choose the branch for your changes.* To work on the ManimCommunity master branch, you can change to it with: - ```sh - git checkout -b master upstream/master - ``` - If you are starting a new branch, execute - ```sh - git checkout -b - ``` -5. Install manim. + .. code-block:: shell - Install the required packages and manim itself: - ```sh - pip install -e . - ``` + git checkout -b master upstream/master - Manim has other requirements that you will need to install, - explained in the [Installation](installation) instructions. + If you are starting a new branch, execute + .. code-block:: shell -6. Write some awesome code! + git checkout -b +#. *Write some awesome code!* You're ready to make changes in your local repository, add them, and commit them. -7. Update docstrings and documentation. - - You should update the docstrings (the text in triple quotation marks) of any functions +#. *Update docstrings and documentation.* + Update the docstrings (the text in triple quotation marks) of any functions or classes you change and include them with any new functions you add. - There is a [Wiki Entry for - Documentation](https://github.com/ManimCommunity/manim/wiki//Documentation-guidelines-(WIP)) - with more information about how we prefer our code to be documented. + There is a `Wiki Entry for + Documentation `_ + with more information about how we prefer our code to be documented. The content + of the docstrings will be rendered in the :doc:`reference manual `. - You must check that the command `make doctest`, executed from the `docs/` folder - terminates without problems after your changes. +#. *Add new or update existing tests.* + Depending on the changes you are making you will need to update or add new tests. + It is strongly preferred that you include tests with your PR. Details of our testing + system are explained in the + `corresponding Wiki Entry `_. -8. Add/update tests. +As far as development on your local machine goes, these are the main steps you +should follow. - Depending on the changes you are making you will need to update or add new tests. - If you have added a new feature or bug fix, it is strongly - preferred that you include tests with your PR. - Please check out the [Wiki Entry for Testing](https://github.com/ManimCommunity/manim/wiki/Testing) - to learn how our tests work. +Polishing your Changes and Submitting them for Review +===================================================== + +As soon as you are ready to share your local changes with the community +so that they can be discussed, go through the following steps to open a +pull request. -9. Check for merge conflicts. +.. NOTE:: - If you want your changes to be incorporated to the main ManimCommunity - repository, you need to make sure that there are no merge conflicts between - the current upstream/master and the changes you are trying to make. To do this - you will need to update your local repo with any changes that have - been made to the ManimCommunity repo while you've been working with - `git pull upstream master`. - This will probably generate merge conflicts that you will need to resolve. + To open a pull request (PR), you do not need to have everything + (code / documentation / tests) complete and ready to go. However, the more complete + your PR is, the easier it will be for community developers to review it, and the + quicker it will be merged. If you open a PR that is still under development + and you want a quick overview or start some discussion about planned + yet-to-be-implemented changes, please mark your PR as a draft. -10. Run the `black` autoformatter. +#. *Update your GitHub fork with local changes.* + To make your changes visible in your GitHub fork, instead of typing in + ``git push`` as usual, you need to enter the command below. - You can run black on a file or directory with `black ` to - format your code to the same standard as the rest of ManimCommunity. - This will make changes to your code, so you will need to add/commit those changes - if you commit before running it. Most python IDE/text editors have packages for - running black after every save if you would like to keep formatting consistent while - you work. + .. code-block:: shell -11. Run `pytest`. + git push -u origin - You can check that everything is still working properly after your modifications - with `pytest`. Make sure that you run the tests locally and that they all pass - before submitting a PR. `pytest` should be run from the main `manim/` - folder (Not the `manim/manim` subfolder). + Doing so creates a new branch with the updated contents of your fork on + GitHub (the 'origin'). -12. Update your GitHub fork with local changes. +#. *Make a Pull Request on Github.* + In order to make the ManimCommunity development team aware of your changes, + you can make a Pull Request to the Manim Community repository from your fork. - To make your changes visible in your GitHub fork, instead of typing in `git - push` as usual, you need to enter the command below. + .. WARNING:: - ```sh - git push -u origin - ``` + Make sure to select ``ManimCommunity/manim`` instead of ``3b1b/manim`` + as the base repository! - Doing so creates a new branch with the updated contents of your fork on - GitHub (the 'origin'). + Choose the branch with your changes from your fork as the head + repository - see the screenshot below. -13. Make a Pull Request on Github. + .. image:: /_static/pull-requests.PNG + :align: center - To request the ManimCommunity dev team to incorporate the changes in your - fork into the main repository, you can make a Pull Request to the Manim - Community repo from your fork. Make sure to select `ManimCommunity/manim` - instead of `3b1b/manim` as the `base repository` and your fork and branch as - `head repository` - see the screenshot below. + Please make sure you follow the template (this is the default + text you are shown when first opening the 'New Pull Request' page). - ![pull-requests-example-manim-community](./_static/pull-requests.PNG) - Please make sure you follow the template (this is the default - text you are shown when first opening the 'New Pull Request' page) +Your changes are eligible to be merged, if +#. there are no merge conflicts, +#. and if the tests in our pipeline passes. -14. Wait for feedback and make any requested changes. +You can check for merge conflicts between the current upstream/master and +your branch by executing ``git pull upstream master`` locally. If this +generates any merge conflicts, you need to resolve them and push an +updated version of the branch to your fork of the repository. - Thank you for contributing! Once your PR is submitted, it will require at least - two approving code reviews from community developers. It will also be automatically - tested. These tests must all pass for the PR to be merged. - You will likely be asked to edit or modify your PR in one way or - another during this process. This is not an indictment of your work, but - rather a strong signal that the dev community wants to merge your changes! +Our pipeline consists of a series of different tests that ensure +that manim still works as intended and that the code you added +sticks to our coding conventions. - Note: To open a PR, you do not need to have everything - (documentation/tests) complete and ready to go. However, the more complete - your PR is, the easier it will be for community devs to review it, and the - quicker it will be merged. If you open a PR that is still under development - and you want a quick overview or start some discussion about planned - yet-to-be-implemented changes, please mark your PR as a draft. +- *Code style*: We use the code style imposed + by `Black `_. The pipeline + makes sure that the (Python) files changed in your pull request + also adhere to this code style. If this step of the pipeline fails, + fix your code style by running ``black `` to + automatically format your files. +- *Tests*: The pipeline runs manim's test suite on different operating systems + (the latest versions of Ubuntu, MacOS, and Windows) for different versions of Python. + The test suite consists of two different kinds of tests: integration tests + and doctests. You can run them locally by executing ``poetry run pytest`` + and ``poetry run pytest --doctest-modules manim``, respectively, from the + root directory of your cloned fork. -## Other guidelines +- *Documentation*: We also build a version of the documentation corresponding + to your pull request. Make sure not to introduce any Sphinx errors, and have + a look at the built HTML files to see whether the formatting of the documentation + you added looks like you intended. You can build the documentation locally + by running ``make html`` from the ``docs`` directory. -1. When submitting a PR, please make special note of whether your proposed +Finally, if the pipeline passes and you are satisfied with your changes: wait for +feedback and iterate over requested changes. You will likely be asked to edit or +modify your PR in one way or another during this process. +This is not an indictment of your work, but rather a strong signal that the +community wants to merge your changes! Overall, in order for your PR to be merged +at least two approving code reviews from core community developers are required. + + +Further useful guideline +======================== + +#. When submitting a PR, please make special note of whether your proposed changes will result in breaking changes. -2. When submitting a PR, make sure that your proposed changes are as general as +#. When submitting a PR, make sure that your proposed changes are as general as possible, and ready to be taken advantage of by all of manim's users. In particular, leave out any machine-specific configurations, or any personal information it may contain. -3. If you are a maintainer, please label issues and PRs appropriately and +#. If you are a maintainer, please label issues and PRs appropriately and frequently. -4. When opening a new issue, if there are old issues that are related, link +#. When opening a new issue, if there are old issues that are related, link them in your new issue (even if the old ones are closed). -5. When submitting a code review, it is highly recommended that you adhere to - [these general guidelines](https://conventionalcomments.org/). Similarly, +#. When submitting a code review, it is highly recommended that you adhere to + `these general guidelines `_. Similarly, when crafting commit messages, it is highly recommended that you adhere to - [these guidelines](https://www.conventionalcommits.org/en/v1.0.0/). + `these guidelines `_. -6. If you find stale or inactive issues that seem to be irrelevant, please post +#. If you find stale or inactive issues that seem to be irrelevant, please post a comment saying 'This issue should be closed', and a community developer will take a look. -7. Please do as much as possible to keep issues, PRs, and development in +#. Please do as much as possible to keep issues, PRs, and development in general as tidy as possible. + + +**Thank you for contributing!** \ No newline at end of file From 530e2c69902a3e1f14be0d3fe1781b4864dd1fd6 Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Sun, 20 Sep 2020 22:15:01 +0200 Subject: [PATCH 5/7] add reference to manim_directive --- docs/source/contributing.rst | 14 ++++++++++++-- docs/source/manim_directive.py | 3 ++- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index da2c4fe1bf..8cb94420af 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -87,6 +87,16 @@ Changing manim's Source Code with more information about how we prefer our code to be documented. The content of the docstrings will be rendered in the :doc:`reference manual `. + .. tip:: + + Use the :mod:`manim directive for Sphinx <.manim_directive>` to add examples + to the documentation! + + .. autosummary:: + :toctree: reference + + manim_directive + #. *Add new or update existing tests.* Depending on the changes you are making you will need to update or add new tests. It is strongly preferred that you include tests with your PR. Details of our testing @@ -183,8 +193,8 @@ community wants to merge your changes! Overall, in order for your PR to be merge at least two approving code reviews from core community developers are required. -Further useful guideline -======================== +Further useful guidelines +========================= #. When submitting a PR, please make special note of whether your proposed changes will result in breaking changes. diff --git a/docs/source/manim_directive.py b/docs/source/manim_directive.py index aa731e13dd..cf92b4c0d4 100644 --- a/docs/source/manim_directive.py +++ b/docs/source/manim_directive.py @@ -72,7 +72,8 @@ def construct(self): class ManimDirective(Directive): - r"""The ``.. manim::`` directive. + r"""The manim directive, rendering videos while building + the documentation. See the module docstring for documentation. """ From a3175a1be5dae54c16426d3a8c5894a724619c6b Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Mon, 21 Sep 2020 02:37:43 +0200 Subject: [PATCH 6/7] remove capitalization --- docs/source/contributing.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index 8cb94420af..fcbaa910d3 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -15,8 +15,8 @@ refactoring code. As our repository is a Fork of `Manim by confusing. Here is a short guide on how to do it. -Setup Manim with Version Control -================================ +Setup Manim and version control +=============================== #. *Make a fork of this repository on Github.* You will need an account with Github. This will allow you to make pull requests (PR) @@ -59,7 +59,7 @@ Setup Manim with Version Control You are now ready to work on manim! -Changing manim's Source Code +Changing manim's source code ============================ #. *Choose the branch for your changes.* @@ -106,7 +106,7 @@ Changing manim's Source Code As far as development on your local machine goes, these are the main steps you should follow. -Polishing your Changes and Submitting them for Review +Polishing your changes and submitting them for review ===================================================== As soon as you are ready to share your local changes with the community From d7a68d5dc5c0fc511e05b7622e939b6575025c4e Mon Sep 17 00:00:00 2001 From: Benjamin Hackl Date: Wed, 23 Sep 2020 10:13:59 +0200 Subject: [PATCH 7/7] fix formatting of a list --- docs/source/contributing.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index fcbaa910d3..93f621d559 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -153,6 +153,7 @@ pull request. Your changes are eligible to be merged, if + #. there are no merge conflicts, #. and if the tests in our pipeline passes.