Skip to content

Commit

Permalink
Add installation details to documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
tillbiskup committed Apr 21, 2021
1 parent 03f4d33 commit 217b1c0
Show file tree
Hide file tree
Showing 4 changed files with 89 additions and 2 deletions.
2 changes: 1 addition & 1 deletion INSTALL.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Installing the ASpecD package
=============================

Installing the ASpecD package is as simple as installing any other Python package, as ASpeD is available from the `Python Package Index (PyPI) <https://www.pypi.org/>`_. Simply open a terminal on your computer and type::
Installing the ASpecD package is as simple as installing any other Python package, as ASpecD is available from the `Python Package Index (PyPI) <https://www.pypi.org/>`_. Simply open a terminal on your computer and type::

pip install aspecd

Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.1.0.dev497
0.1.0.dev498
13 changes: 13 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,18 @@ If you are interested in how working with the ASpecD framework looks like, parti
The :doc:`API documentation <api/index>` is the definite source of information for developers, besides having a look at the source code.


Installation
------------

To install the ASpecD framework on your computer (sensibly within a Python virtual environment), open a terminal (activate your virtual environment), and type in the following:

.. code-block:: bash
pip install aspecd
Have a look at the more detailed :doc:`installation instructions <installing>` as well.


Related projects
----------------

Expand Down Expand Up @@ -112,6 +124,7 @@ Finally, don't forget to check out the website on `reproducible research <https:
recipes
usecases
applications
installing

.. toctree::
:maxdepth: 2
Expand Down
74 changes: 74 additions & 0 deletions docs/installing.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
Installation
============

Installing the ASpecD package is as simple as installing any other Python package, as ASpecD is available from the `Python Package Index (PyPI) <https://www.pypi.org/>`_. Simply open a terminal on your computer and type::

pip install aspecd

This will install the ASpecD package (and all its dependencies) on your computer.

Of course, you need to have Python (and pip) installed before you can use the above command, and it is always advisable to install packages in a **virtual environment** of their own.

Hence, a more thorough sequence of events would be:

#. Install Python (if it is not already installed on your system).

#. Create a Python virtual environment for ASpecD.

#. Activate the newly created virtual environment.

#. Install ASpecD therein, using the above command.

A few details for all these steps are given below.


Installing Python
-----------------

For how to install Python on your system, see the `official documentation <https://wiki.python.org/moin/BeginnersGuide/Download>`_. Linux users: you will most certainly have Python installed already.


Create a Python virtual environment
-----------------------------------

It is good practice to always use virtual environments when working with Python. One reason: On some operating systems, crucial tasks depend on Python, and installing Python packages globally may interfere with the system.

The good news: Creating Python virtual environments is fairly simple:

.. code-block:: bash
python -m venv aspecd
This will create a Python virtual environment named ``aspecd`` in the current directory. Of course, you can give your virtual environment any name you like. However, be careful with spaces and special characters, depending on your system.


Activate the newly created virtual environment
----------------------------------------------

A Python virtual environment needs to be activated. This is usually done using the following command:

.. code-block:: bash
source aspecd/bin/activate
Assuming in this case that your virtual environment is called ``aspecd`` and that you are in the same path where you just created your virtual environment.

Deactivating is simple as well, once you are done. Either close the terminal, or issue the command ``deactivate``.


Install ASpecD
--------------

Once you activated your virtual environment where you want to install the ASpecD framework in, proceed as given above:

.. code-block:: bash
pip install aspecd
This will download the ASpecD framework from the `Python Package Index (PyPI) <https://www.pypi.org/>`_ and install it locally. All dependencies will be installed as well.


.. note::

The above instructions assume a fairly standard Python installation using pip. Of course, there are other Python distributions available as well, such as conda. If you are using such a Python distribution, pip should be available as well. However, in case of problems consult the documentation of your respective Python distribution for details.

0 comments on commit 217b1c0

Please sign in to comment.