archinstall/docs/installing/python.rst

1.5 KiB

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> </head>

Python library

Archinstall ships on PyPi as archinstall. But the library can be installed manually as well.

Warning

This is not required if you're running archinstall on a pre-built ISO. The installation is only required if you're creating your own scripted installations.

Using pacman

Archinstall is on the official repositories.

To install both the library and the archinstall script:

System Message: WARNING/2 (<stdin>, line 19)

Cannot analyze code. Pygments package not found.

.. code-block:: console

    sudo pacman -S archinstall

Or, to install just the library:

System Message: WARNING/2 (<stdin>, line 25)

Cannot analyze code. Pygments package not found.

.. code-block:: console

    sudo pacman -S python-archinstall

Using PyPi

The basic concept of PyPi applies using pip. Either as a global library:

System Message: WARNING/2 (<stdin>, line 35)

Cannot analyze code. Pygments package not found.

.. code-block:: console

    sudo pip install archinstall

Or as a user module:

System Message: WARNING/2 (<stdin>, line 41)

Cannot analyze code. Pygments package not found.

.. code-block:: console

    pip --user install archinstall

Which will allow you to start using the library.

Manual installation

You can either download the github repo as a zip archive. Or you can clone it, we'll clone it here but both methods work the same.

System Message: WARNING/2 (<stdin>, line 55)

Cannot analyze code. Pygments package not found.

.. code-block:: console

    git clone https://github.com/Torxed/archinstall

Either you can move the folder into your project and simply do

System Message: WARNING/2 (<stdin>, line 61)

Cannot analyze code. Pygments package not found.

.. code-block:: python

    import archinstall

Or you can use setuptools to install it into the module path.

System Message: WARNING/2 (<stdin>, line 67)

Cannot analyze code. Pygments package not found.

.. code-block:: console

    sudo python setup.py install
</html>