docs: Fix sphinx warnings

Related to T2188
This commit is contained in:
Antoine Lambert 2020-01-17 15:42:18 +01:00
parent 4b383abc56
commit 99fcd2b3f5
6 changed files with 64 additions and 67 deletions

View file

@ -14,12 +14,11 @@ Overview
.. toctree::
:maxdepth: 2
:caption: Overview:
:titlesonly:
lister-tutorial
run-lister-tutorial
tutorial
run_a_new_lister
Reference Documentation

View file

@ -33,19 +33,21 @@ class CGitLister(ListerBase):
If several "Clone" urls are provided, prefer the http/https one, if
any, otherwise fall bak to the first one.
A loader task is created for each git repository:
A loader task is created for each git repository::
Task:
Type: load-git
Policy: recurring
Args:
<git_clonable_url>
Task:
Type: load-git
Policy: recurring
Args:
<git_clonable_url>
Example:
Type: load-git
Policy: recurring
Args:
'https://git.savannah.gnu.org/git/elisp-es.git'
Example::
Task:
Type: load-git
Policy: recurring
Args:
'https://git.savannah.gnu.org/git/elisp-es.git'
"""
MODEL = CGitModel
DEFAULT_URL = 'https://git.savannah.gnu.org/cgit/'

View file

@ -57,25 +57,25 @@ class ListerHttpTransport(abc.ABC):
lister's instance name, which value is expected to be a list of
credential structures (typically a couple username/password).
For example:
For example::
credentials:
github: # github lister
github: # has only one instance (so far)
- username: some
password: somekey
- username: one
password: onekey
- ...
gitlab: # gitlab lister
riseup: # has many instances
- username: someone
password: ...
- ...
gitlab:
- username: someone
password: ...
- ...
credentials:
github: # github lister
github: # has only one instance (so far)
- username: some
password: somekey
- username: one
password: onekey
- ...
gitlab: # gitlab lister
riseup: # has many instances
- username: someone
password: ...
- ...
gitlab:
- username: someone
password: ...
- ...
Returns:
list of credential dicts for the current lister.

View file

@ -70,29 +70,20 @@ class CRANLister(SimpleLister):
containing data about the R packages.
Returns:
List of Dict about r packages. For example:
.. code-block:: python
List of Dict about R packages. For example::
[
{
'Package': 'A3',
'Version': '1.0.0',
'Title':
'Accurate, Adaptable, and Accessible Error Metrics
for Predictive\nModels',
'Description':
'Supplies tools for tabulating and analyzing the
results of predictive models. The methods employed
are ... '
'Title': 'A3 package',
'Description': ...
},
{
'Package': 'abbyyR',
'Version': '0.5.4',
'Title':
'Access to Abbyy OCR (OCR) API',
'Description': 'Get text from images of text using
Abbyy Cloud Optical Character\n ...'
'Title': 'Access to Abbyy OCR (OCR) API',
'Description': ...'
},
...
]

View file

@ -77,16 +77,19 @@ class GNULister(SimpleLister):
response: Unused
Returns:
List of packages name, url, last modification time
List of packages name, url, last modification time::
.. code-block:: python
[
{'name': '3dldf',
'url': 'https://ftp.gnu.org/gnu/3dldf/',
'time_modified': '2003-12-09T20:43:20+00:00'},
{'name': '8sync',
'url': 'https://ftp.gnu.org/gnu/8sync/',
'time_modified': '2016-12-06T02:37:10+00:00'},
{
'name': '3dldf',
'url': 'https://ftp.gnu.org/gnu/3dldf/',
'time_modified': '2003-12-09T20:43:20+00:00'
},
{
'name': '8sync',
'url': 'https://ftp.gnu.org/gnu/8sync/',
'time_modified': '2016-12-06T02:37:10+00:00'
},
...
]

View file

@ -33,21 +33,23 @@ class PackagistLister(ListerOnePageApiTransport, SimpleLister):
variable `PAGE`, to receive a list of all the package names
present in the Packagist package manager. Iterates over all the
packages and constructs the metadata url of the package from
the name of the package and creates a loading task.
the name of the package and creates a loading task::
Task:
Type: load-packagist
Policy: recurring
Args:
<package_name>
<package_metadata_url>
Task:
Type: load-packagist
Policy: recurring
Args:
<package_name>
<package_metadata_url>
Example:
Type: load-packagist
Policy: recurring
Args:
'hypejunction/hypegamemechanics'
'https://repo.packagist.org/p/hypejunction/hypegamemechanics.json'
Example::
Task:
Type: load-packagist
Policy: recurring
Args:
'hypejunction/hypegamemechanics'
'https://repo.packagist.org/p/hypejunction/hypegamemechanics.json'
"""
MODEL = PackagistModel