Skip to content
This repository has been archived by the owner on May 25, 2023. It is now read-only.

Commit

Permalink
Build HTML documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
kelvins committed Oct 6, 2019
1 parent 49adb9b commit db63c56
Show file tree
Hide file tree
Showing 49 changed files with 16,708 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .gitignore
Expand Up @@ -64,7 +64,7 @@ instance/
.scrapy

# Sphinx documentation
docs/_build/
#docs/_build/

# PyBuilder
target/
Expand Down
Binary file added docs/_build/doctrees/changelog.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/commands.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/contributing.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/environment.pickle
Binary file not shown.
Binary file added docs/_build/doctrees/index.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/modules.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/nomade.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/quickstart.doctree
Binary file not shown.
Binary file added docs/_build/doctrees/settings.doctree
Binary file not shown.
4 changes: 4 additions & 0 deletions docs/_build/html/.buildinfo
@@ -0,0 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: c9029b17966ef819213e3a3231729aa3
tags: 645f666f9bcd5a90fca523b33c5a78b7
21 changes: 21 additions & 0 deletions docs/_build/html/_images/logo.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/_build/html/_sources/changelog.rst.txt
@@ -0,0 +1 @@
.. include:: ../CHANGELOG.rst
91 changes: 91 additions & 0 deletions docs/_build/html/_sources/commands.rst.txt
@@ -0,0 +1,91 @@
Commands
========

Here you can find a description of all ``Nomade`` commands:

Version
-------

Show the ``Nomade`` version.

Usage:

$ nomade version

Init
----

Initialize a ``Nomade`` project.

Usage:

$ nomade init

Migrate
-------

Create a new ``Nomade`` migration.

Usage:

$ nomade migrate "My First Migration"

Upgrade
-------

Upgrade database version.

Usage:

$ nomade upgrade head

$ nomade upgrade 1

Downgrade
---------

Downgrade database version.

Usage:

$ nomade downgrade tail

$ nomade downgrade 1

History
-------

Show migration history.

Usage:

$ nomade history

Current
-------

Show the current migration applied in the database.

Usage:

$ nomade current

Help
----

Show ``Nomade`` helper.

Usage:

$ nomade --help

Stamp
-----

Stamp a specific migration to the database.

**Note**: this command will not run any migration, it will only save the migration ID in the database.

Usage:

$ nomade stamp u19jh2h1
1 change: 1 addition & 0 deletions docs/_build/html/_sources/contributing.rst.txt
@@ -0,0 +1 @@
.. include:: ../CONTRIBUTING.rst
29 changes: 29 additions & 0 deletions docs/_build/html/_sources/index.rst.txt
@@ -0,0 +1,29 @@
.. Nomade documentation master file, created by
sphinx-quickstart on Sat Aug 24 23:24:41 2019.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
RST examples: https://pythonhosted.org/an_example_pypi_project/sphinx.html
.. image:: ../artwork/logo.svg
:alt: Nomade: Python Migration Manager for Humans
:align: center
:width: 250

Introduction
============

Python Migration Manager for Humans.

Nomade is a simple migration manager tool that aims to be easy to integrate with any ORM.

.. toctree::
:maxdepth: 2
:caption: Contents:

quickstart
commands
settings
Contributing <contributing>
changelog
modules

7 changes: 7 additions & 0 deletions docs/_build/html/_sources/modules.rst.txt
@@ -0,0 +1,7 @@
nomade
======

.. toctree::
:maxdepth: 4

nomade
70 changes: 70 additions & 0 deletions docs/_build/html/_sources/nomade.rst.txt
@@ -0,0 +1,70 @@
nomade package
==============

Submodules
----------

nomade.database module
----------------------

.. automodule:: nomade.database
:members:
:undoc-members:
:show-inheritance:

nomade.main module
------------------

.. automodule:: nomade.main
:members:
:undoc-members:
:show-inheritance:

nomade.migration module
-----------------------

.. automodule:: nomade.migration
:members:
:undoc-members:
:show-inheritance:

nomade.migrations module
------------------------

.. automodule:: nomade.migrations
:members:
:undoc-members:
:show-inheritance:

nomade.nomad module
-------------------

.. automodule:: nomade.nomad
:members:
:undoc-members:
:show-inheritance:

nomade.settings module
----------------------

.. automodule:: nomade.settings
:members:
:undoc-members:
:show-inheritance:

nomade.utils module
-------------------

.. automodule:: nomade.utils
:members:
:undoc-members:
:show-inheritance:


Module contents
---------------

.. automodule:: nomade
:members:
:undoc-members:
:show-inheritance:
43 changes: 43 additions & 0 deletions docs/_build/html/_sources/quickstart.rst.txt
@@ -0,0 +1,43 @@
Quick Start
===========

Here you can find a quick tutorial with basic ``Nomade`` commands.

virtualenv
----------

We recommend the use of a virtual environment to run develop any Python project. You can create a virtual environment using ``virtualenv`` tool, for example:

$ pip install virtualenv

$ virtualenv venv

$ source venv/bin/activate

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

With the virtual environment created and activated you are ready to go. Go ahead and install ``Nomade`` with:

$ pip install nomade

Basic commands
--------------

Initialize a ``Nomade`` project with:

$ nomade init

Set the settings in the `pyproject.toml` file.

Then, create your first migration:

$ nomade migrate "My first migration"

Then apply the migration to the database:

$ nomade upgrade head

These are the basic ``Nomade`` commands, to discover more features please read the :doc:`Commands <commands>` section or run the following command:

$ nomade --help
25 changes: 25 additions & 0 deletions docs/_build/html/_sources/settings.rst.txt
@@ -0,0 +1,25 @@
Settings
========

**Nomade** can be customized by defining the following settings in the ``pyproject.toml`` file.

Description
-----------

- **migrations**: Path to the migrations folder.
- **template**: Path to the template file.
- **connection-string**: String to connect to the database. The connection string can also be set by an environment variable (``CONNECTION_STRING``).
- **date-format**: Date format (follows the `Python date format <https://docs.python.org/3/library/datetime.html>`_).
- **name-format**: Name format (options are: ``date``, ``time``, ``id`` and ``slug``).

Example
-------

::

[tool.nomade]
migrations = "nomade/migrations"
template = "nomade/template.py.j2"
connection-string = "sqlite:///nomade.db"
date-format = "%d/%m/%Y"
name-format = "{date}_{time}_{id}_{slug}"

0 comments on commit db63c56

Please sign in to comment.