Skip to content

Commit

Permalink
Merge pull request #263 from alneberg/update_doc
Browse files Browse the repository at this point in the history
Bugfix for the new documentation
  • Loading branch information
alneberg committed Aug 1, 2019
2 parents cd90a08 + 90826b0 commit 662de76
Show file tree
Hide file tree
Showing 8 changed files with 29 additions and 13 deletions.
1 change: 1 addition & 0 deletions doc/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ Sphinx>=1.3.1
mock>=1.0.1
sphinxcontrib-programoutput>=0.8
sphinx-rtd-theme>=0.1.6
conf
2 changes: 1 addition & 1 deletion doc/source/cmd_options.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ CONCOCT uses several command line options to control the clustering, here is a
complete documentation of these. These can also be viewed by typing ``concoct
-h`` on the command line:

.. program-output:: (concoct -h)
.. program-output:: (echo 'import conf'; tail -n+2 ../../concoct/parser.py; echo 'args=arguments()') | python - --help
:shell:
17 changes: 17 additions & 0 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,3 +299,20 @@

# If true, do not generate a @detailmenu in the "Top" node's menu.
#texinfo_no_detailmenu = False

# -- Read the Docs C module import issues -------------------------------------

# See:
# http://read-the-docs.readthedocs.org/en/latest/faq.html#i-get-import-errors-on-libraries-that-depend-on-c-modules
from mock import Mock as MagicMock

class Mock(MagicMock):
@classmethod
def __getattr__(cls, name):
return Mock()

MOCK_MODULES = ['pygtk', 'gtk', 'gobject', 'numpy', 'pandas', 'Bio', 'concoct',
'concoct.utils', 'concoct.output', 'concoct.parser', 'concoct.cluster',
'concoct.input', 'concoct.transform', 'vbgmm']
update_d = {mod_name: Mock() for mod_name in MOCK_MODULES}
sys.modules.update(update_d)
6 changes: 3 additions & 3 deletions doc/source/scripts/concoct_coverage_table.rst
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
======================
=========================
concoct_coverage_table.py
======================
=========================

Usage
=====
The usage and help documentation of ``concoct_coverage_table.py`` can be seen by
running ``concoct_coverage_table.py -h``:

.. program-output:: python ../../scripts/concoct_coverage_table.py -h
.. program-output:: cat ../../scripts/concoct_coverage_table.py | sed 's/import argparse/import argparse, conf/' | python - --help
:shell:

Example
Expand Down
4 changes: 1 addition & 3 deletions doc/source/scripts/cut_up_fasta.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Usage
The usage and help documentation of ``cut_up_fasta.py`` can be seen by
running ``cut_up_fasta.py -h``:

.. program-output:: python ../../scripts/cut_up_fasta.py -h
.. program-output:: cat ../../scripts/cut_up_fasta.py | sed 's/import argparse/import argparse, conf/' | python - --help
:shell:

Example
Expand All @@ -19,5 +19,3 @@ An example of how to run ``cut_up_fasta.py``::
This creates a fasta file and a BED file.
The fasta file ``contigs_10K.fa`` contains the original contigs cut up into parts of length exactly 10K, except for the last contig part which is between 10K and 20K long.
The BED file ``contigs_10K.bed`` contains a list of the contig parts created with coordinates in the original contigs.

.. _cut_up_fasta
2 changes: 1 addition & 1 deletion doc/source/scripts/extract_fasta_bins.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Usage
The usage and help documentation of ``extract_fasta_bins.py`` can be seen by
running ``extract_fasta_bins.py -h``:

.. program-output:: python ../../scripts/extract_fasta_bins.py -h
.. program-output:: cat ../../scripts/extract_fasta_bins.py | sed 's/import argparse/import argparse, conf/' | python - --help
:shell:

Example
Expand Down
4 changes: 2 additions & 2 deletions doc/source/scripts/extract_scg_bins.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
======================
================================
[Deprecated] extract_scg_bins.py
======================
================================

Usage
=====
Expand Down
6 changes: 3 additions & 3 deletions doc/source/scripts/merge_cutup_clustering.rst
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
======================
=========================
merge_cutup_clustering.py
======================
=========================

Usage
=====
The usage and help documentation of ``merge_cutup_clustering.py`` can be seen by
running ``merge_cutup_clustering.py -h``:

.. program-output:: python ../../scripts/merge_cutup_clustering.py -h
.. program-output:: cat ../../scripts/merge_cutup_clustering.py | sed 's/import argparse/import argparse, conf/' | python - --help
:shell:

Example
Expand Down

0 comments on commit 662de76

Please sign in to comment.