Skip to content

Commit

Permalink
Updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
mikicz committed Mar 16, 2018
1 parent 50ebcb3 commit 209915c
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Getting started
Glossary
++++++++

* **Arca** - name of the library. When written as :class:`Arca`, the main interface class is being referenced.
* **Arca** - name of the library. When written as ``Arca``, the main interface class is being referenced.
* **Backend** - a way of running tasks
* **Task** - definition of the script, consists of a reference to a callable object and arguments.

Expand All @@ -39,8 +39,9 @@ Requirements

Requirements for certain backends:

* `Docker <https://www.docker.com/>`_ (for :ref:`Docker Backend <backends_doc>` and :ref:`Vagrant Backend <backends_vag>`)
* `Vagrant <https://www.vagrantup.com/>`_ (for the :ref:`Vagrant Backend <backends_vag>`)
* `Docker <https://www.docker.com/>`_ (for `Docker Backend <https://arca.readthedocs.io/en/latest/backends.html#docker>`_
and `Vagrant Backend <https://arca.readthedocs.io/en/latest/backends.html#vagrant>`_)
* `Vagrant <https://www.vagrantup.com/>`_ (for the `Vagrant Backend <https://arca.readthedocs.io/en/latest/backends.html#vagrant>`_)

Installation
------------
Expand All @@ -60,9 +61,9 @@ Or if you wish to install the upstream version:
Hello World example
+++++++++++++++++++

To run a Hello World example you'll only need the :class:`arca.Arca` and :class:`arca.Task` classes.
:class:`Task <arca.Task>` is used for defining the task that's supposed to be run in the repositories.
:class:`Arca <arca.Arca>` takes care of all the settings and provides the basic API for running tasks.
To run a Hello World example you'll only need the ``arca.Arca`` and ``arca.Task`` classes.
``Task`` is used for defining the task that's supposed to be run in the repositories.
``Arca`` takes care of all the settings and provides the basic API for running tasks.

Let's imagine we have the following file, called ``hello_world.py``, in a repository ``https://example.com/hello_word.git``,
on branch ``master``.
Expand All @@ -84,12 +85,13 @@ To call the function using Arca, the following example would do so:
result = arca.run("https://example.com/hello_word.git", "master", task)
print(result.output)
The code would print ``Hello World!``. ``result`` would be a :class:`Result <arca.Result>` instance which currently only has one
The code would print ``Hello World!``. ``result`` would be a ``arca.Result`` instance which currently only has one
attribute ``output`` with the output of the function call.
If the task failed, :class:`arca.exceptions.BuildError` would be raised.
If the task failed, ``arca.exceptions.BuildError`` would be raised.

By default, the :ref:`Current Environment Backend <backends_cur>` is used to run tasks, which uses the python installation which is used to run
Arca, launching the code in a subprocess. You can learn about backends :ref:`here <backends>`.
By default, the `Current Environment Backend <https://arca.readthedocs.io/en/latest/backends.html#current-environment>`_
is used to run tasks, which uses the python installation which is used to run
Arca, launching the code in a subprocess. You can learn about backends `here <https://arca.readthedocs.io/en/latest/backends.html>`_.

Further reading
***************
Expand Down Expand Up @@ -121,6 +123,7 @@ Links
- PyPi package: `arca <https://pypi.python.org/pypi/arca>`_
- CI: `Travis <https://travis-ci.org/mikicz/arca>`_
- Test coverage: `Codecov <https://codecov.io/gh/mikicz/arca>`_
- Documentation: `Read The Docs <https://arca.readthedocs.io/>`_.

License
*******
Expand Down

0 comments on commit 209915c

Please sign in to comment.