Skip to content

Commit

Permalink
Rewrite installation instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonGrace2282 committed Sep 2, 2024
1 parent 74f79a4 commit a5b1268
Show file tree
Hide file tree
Showing 6 changed files with 145 additions and 103 deletions.
1 change: 1 addition & 0 deletions docs/source/faq/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ of [ManimPango's README](https://github.com/ManimCommunity/ManimPango).

---

(not-on-path)=
## I am using Windows and get the error `X is not recognized as an internal or external command, operable program or batch file`

Regardless of whether `X` says `python` or `manim`, this means that the executable you
Expand Down
22 changes: 16 additions & 6 deletions docs/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ Manim is a Python library, and it can be
installed via `pip <https://pypi.org/project/manim/>`__
or `conda <https://anaconda.org/conda-forge/manim/>`__. However,
in order for Manim to work properly, some additional system
dependencies need to be installed first. The following pages have
operating system specific instructions for you to follow.
dependencies need to be installed first.

Manim requires Python version ``3.9`` or above to run.

Expand All @@ -80,12 +79,23 @@ Manim requires Python version ``3.9`` or above to run.
Discussion `directly on GitHub
<https://github.com/ManimCommunity/manim/discussions>`__.


To install Manim locally, check out the following pages. Note
that the process for Linux is slightly different - if you're
on Linux please follow the instructions in the `Linux section <installation/linux>`_.

.. toctree::
:maxdepth: 2
:maxdepth: 1

installation/locally


Once you've installed the core dependencies, you can proceed to
install the optional dependencies, depending on your system.

installation/windows
installation/macos
installation/linux
- :doc:`installation/windows`
- :doc:`installation/macos`
- :doc:`installation/linux`

Once Manim is installed locally, you can proceed to our
:doc:`quickstart guide <tutorials/quickstart>` which walks you
Expand Down
19 changes: 12 additions & 7 deletions docs/source/installation/linux.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Then, installing Manim is just a matter of running:

In light of the current efforts of migrating to rendering via OpenGL,
this list might be incomplete. Please `let us know
<https://github.com/ManimCommunity/manim/issues/new/choose>` if you
<https://github.com/ManimCommunity/manim/issues/new/choose>`__ if you
ran into missing dependencies while installing.

In any case, we have also compiled instructions for several common
Expand All @@ -29,6 +29,13 @@ combinations of operating systems and package managers below.
Required Dependencies
---------------------

.. tip::

If you have multiple Python versions installed, you might need to install the python
development headers for the correct version. For example, if you have Python 3.9 installed,
you would need to install python3.9-dev.


apt – Ubuntu / Mint / Debian
****************************

Expand Down Expand Up @@ -95,8 +102,7 @@ Cairo and Pango:

.. code-block:: bash
sudo pacman -Syu
sudo pacman -S cairo pango
sudo pacman -Syu cairo pango
If you don't have ``python-pip`` installed, get it by running:

Expand Down Expand Up @@ -147,13 +153,12 @@ Should you choose to work with some smaller TeX distribution like
of LaTeX packages which Manim interacts with in some way (a subset might
be sufficient for your particular application) is::

collection-basic amsmath babel-english cbfonts-fd cm-super ctex doublestroke
dvisvgm everysel fontspec frcursive fundus-calligra gnu-freefont jknapltx
latex-bin mathastext microtype ms physics preview ragged2e relsize rsfs
amsmath babel-english cbfonts-fd cm-super count1to ctex doublestroke dvisvgm everysel
fontspec frcursive fundus-calligra gnu-freefont jknapltx latex-bin
mathastext microtype multitoc physics preview prelim2e ragged2e relsize rsfs
setspace standalone tipa wasy wasysym xcolor xetex xkeyval



Working with Manim
------------------

Expand Down
109 changes: 109 additions & 0 deletions docs/source/installation/locally.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
Installing Manim Locally
************************
For the most part, installing Manim is the same across operating systems. However,
you can take some shortcuts depending on your operating system.

- MacOS users can use `Homebrew <https://brew.sh>`_ to install Manim - check out the section for :ref:`MacOS<macos_homebrew>`.


However, if you don't want to use a package manager, check out the section for :ref:`all operating systems<all_os>`.

.. _all_os:

All Operating Systems
=====================
Manim requires a Python version of at least ``3.9`` to run.
If you're not sure if you have python installed, or want to check
what version of Python you have, try running::

python --version

If it errors out, you most likely don't have Python installed. Otherwise, if your
python version is ``3.9`` or higher, you can proceed to :ref:`installing Manim with Pip<manim_pip>`.

.. hint::

On MacOS and some Linux distributions, you may have to use ``python3`` instead of ``python``.
In this document, we will use ``python``, but depending on your operating system you may have to
use ``python3``.

Installing Python
-----------------
If you don't have Python installed, head over to https://www.python.org, download an installer
for a recent (preferably the latest) version of Python, and follow its instructions to get Python
installed on your system.

.. note::

We have received reports of problems caused by using the version of
Python that can be installed from the Windows Store. At this point,
we recommend staying away from the Windows Store version. Instead,
install Python directly from the `official website <https://www.python.org>`__.


After installing Python, running the command::

python --version

Should be successful. If it is not, try checking out :ref:`this FAQ entry<not-on-path>`.

.. _manim_pip:

Installing Manim
----------------
At this point, installing manim should be as easy as running::

python -m pip install manim

To confirm Manim is working, you can run::

manim --version


.. _macos_homebrew:

MacOS
=====
The easiest way to install Manim on macOS is via the popular `package manager Homebrew <https://brew.sh>`__.
If you want to use Homebrew but do not have it installed yet, please
follow `Homebrew's installation instructions <https://docs.brew.sh/Installation>`__.

.. note::

For a while after Apple released its new ARM-based processors (the Apple Silicon chips like the *"M1 chip"*),
the recommended way of installing Manim relied on *Rosetta*, Apple's compatibility
layer between Intel and ARM architectures. This is no longer necessary, Manim can
(and is recommended to) be installed natively.

Manim has a Homebrew formula, so you can just run::

brew install manim

And you should have Manim all installed! Head on over to install the :ref:`optional dependencies<optional_dependencies>`.


.. _optional_dependencies:

Optional Dependencies
=====================
At this point, Manim should be fully working! However,
many Manim objects depend on ``LaTeX``, a math typesetting system.
How to install a texlive distribution varies across operating systems,
so check out the document that matches your operating system below:

.. toctree::
:maxdepth: 1

windows
macos
linux

To confirm all dependencies are installed and working, run::

manim checkhealth


Working with Manim
==================
Head over to our :doc:`Quickstart Tutorial <../tutorials/quickstart>` to learn
how to make your own *Manimations*!
33 changes: 4 additions & 29 deletions docs/source/installation/macos.rst
Original file line number Diff line number Diff line change
@@ -1,31 +1,6 @@
macOS
MacOS
=====

For the sake of simplicity, the following instructions assume that you have
the popular `package manager Homebrew <https://brew.sh>`__ installed. While
you can certainly also install all dependencies without it, using Homebrew
makes the process much easier.

If you want to use Homebrew but do not have it installed yet, please
follow `Homebrew's installation instructions <https://docs.brew.sh/Installation>`__.

.. note::

For a while after Apple released its new ARM-based processors (the Apple Silicon chips like the *"M1 chip"*),
the recommended way of installing Manim relied on *Rosetta*, Apple's compatibility
layer between Intel and ARM architectures. This is no longer necessary, Manim can
(and is recommended to) be installed natively.


Installing Manim
----------------

As of July/2024, brew can install Manim including all required dependencies.
To install Manim:

.. code-block:: bash
brew install manim
For installing Manim, please refer to the :doc:`installation instructions <../installation>`.

.. _macos-optional-dependencies:

Expand Down Expand Up @@ -56,9 +31,9 @@ Should you choose to work with some partial TeX distribution, the full list
of LaTeX packages which Manim interacts with in some way (a subset might
be sufficient for your particular application) is::

amsmath babel-english cbfonts-fd cm-super ctex doublestroke dvisvgm everysel
amsmath babel-english cbfonts-fd cm-super count1to ctex doublestroke dvisvgm everysel
fontspec frcursive fundus-calligra gnu-freefont jknapltx latex-bin
mathastext microtype ms physics preview ragged2e relsize rsfs
mathastext microtype multitoc physics preview prelim2e ragged2e relsize rsfs
setspace standalone tipa wasy wasysym xcolor xetex xkeyval


Expand Down
64 changes: 3 additions & 61 deletions docs/source/installation/windows.rst
Original file line number Diff line number Diff line change
@@ -1,64 +1,6 @@
Windows
=======

The easiest way of installing Manim and its dependencies is by using a
package manager like `Chocolatey <https://chocolatey.org/>`__
or `Scoop <https://scoop.sh>`__, especially if you need optional dependencies
like LaTeX support.

If you choose to use one of the package managers, please follow
their installation instructions
(`for Chocolatey <https://chocolatey.org/install#install-step2>`__,
`for Scoop <https://scoop-docs.now.sh/docs/getting-started/Quick-Start.html>`__)
to make one of them available on your system.


Required Dependencies
---------------------

Manim requires a recent version of Python (3.9 or above)
in order to work.

Chocolatey
**********

Manim can be installed via Chocolatey simply by running:

.. code-block:: powershell
choco install manimce
That's it, no further steps required. You can continue with installing
the :ref:`optional dependencies <win-optional-dependencies>` below.

Pip
***

As mentioned above, Manim needs a reasonably recent version of
Python 3 (3.9 or above).

**Python:** Head over to https://www.python.org, download an installer
for a recent version of Python, and follow its instructions to get Python
installed on your system.

.. note::

We have received reports of problems caused by using the version of
Python that can be installed from the Windows Store. At this point,
we recommend staying away from the Windows Store version. Instead,
install Python directly from the
`official website <https://www.python.org>`__.

Then, Manim can be installed via Pip simply by running:

.. code-block:: powershell
python -m pip install manim
Manim should now be installed on your system. Continue reading
the :ref:`optional dependencies <win-optional-dependencies>` section
below.

For installing Manim, please refer to the :doc:`installation instructions <../installation>`.

.. _win-optional-dependencies:

Expand Down Expand Up @@ -93,9 +35,9 @@ Therefore we only recommend this option if you know what you are doing.
The full list of LaTeX packages which Manim interacts with in some way
(a subset might be sufficient for your particular application) are::

amsmath babel-english cbfonts-fd cm-super ctex doublestroke dvisvgm everysel
amsmath babel-english cbfonts-fd cm-super count1to ctex doublestroke dvisvgm everysel
fontspec frcursive fundus-calligra gnu-freefont jknapltx latex-bin
mathastext microtype ms physics preview ragged2e relsize rsfs
mathastext microtype multitoc physics preview prelim2e ragged2e relsize rsfs
setspace standalone tipa wasy wasysym xcolor xetex xkeyval


Expand Down

0 comments on commit a5b1268

Please sign in to comment.