diff --git a/docs/source/_static/css/custom.css b/docs/source/_static/css/custom.css new file mode 100644 index 0000000..b578848 --- /dev/null +++ b/docs/source/_static/css/custom.css @@ -0,0 +1,10 @@ +body { + --themecolor: #4f4f4f; +} + +.wy-side-nav-search { + background-color: var(--themecolor); +} +.wy-nav-top { + background-color: var(--themecolor); +} diff --git a/docs/source/_static/logo.svg b/docs/source/_static/logo.svg index a728dd2..8234938 100644 --- a/docs/source/_static/logo.svg +++ b/docs/source/_static/logo.svg @@ -1,10 +1,479 @@ - - - - -.momics + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + O + I + S + M + M + C + diff --git a/docs/source/cli/index.rst b/docs/source/cli/index.rst index 90a7560..0210efd 100644 --- a/docs/source/cli/index.rst +++ b/docs/source/cli/index.rst @@ -3,6 +3,84 @@ CLI Reference ============= +.. toctree:: + :maxdepth: 1 + +Contents +-------- + +.. program:: momics +.. code-block:: shell + + momics [OPTIONS] COMMAND [ARGS]... + +.. list-table:: + :widths: 25 100 + :align: left + :header-rows: 1 + + * - Data management + - + * - `momics create <#momics-create>`_ + - Create a repository + * - `momics delete <#momics-delete>`_ + - Delete a repository + * - `momics ingest <#momics-ingest>`_ + - Ingest datasets + * - `momics cp <#momics-cp>`_ + - Copy datasets + * - `momics remove <#momics-remove>`_ + - Remove datasets + * - `momics ls <#momics-ls>`_ + - List tables + + +.. list-table:: + :widths: 25 100 + :align: left + :header-rows: 1 + + * - Data query engine + - + * - `momics query <#momics-query>`_ + - Query a repository + + +.. list-table:: + :widths: 25 100 + :align: left + :header-rows: 1 + + * - Cloud configuration + - + * - `momics config <#momics-config>`_ + - Create a repository + +.. list-table:: + :widths: 25 100 + :align: left + :header-rows: 1 + + * - Momics utils + - + * - `momics tree <#momics-tree>`_ + - List repository content + * - `momics binnify <#momics-binnify>`_ + - Binnify a genome + +.. rubric:: Options + +.. option:: -v, --version + + Show the version and exit. + +.. option:: -h, --help + + Show help menu and exit. + + +---- + .. click:: momics.cli:cli :prog: momics :nested: full diff --git a/docs/source/conf.py b/docs/source/conf.py index 37a6f03..ebf40b7 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -35,7 +35,6 @@ "sphinx.ext.mathjax", "sphinx.ext.ifconfig", "sphinx.ext.viewcode", - "sphinx.ext.autosummary", "sphinx.ext.napoleon", "sphinx_click.ext", "myst_parser", @@ -45,7 +44,6 @@ myst_heading_anchors = 2 source_suffix = [".rst", ".md"] -autosummary_generate = True numpydoc_show_class_members = True napoleon_use_rtype = True autodoc_typehints = "description" @@ -60,6 +58,7 @@ html_static_path = ["_static"] html_logo = "_static/logo.svg" html_favicon = "_static/logo.svg" +html_css_files = ["css/custom.css"] html_sourcelink_suffix = "" html_last_updated_fmt = "" htmlhelp_basename = "momicsdoc" @@ -72,6 +71,7 @@ html_theme_options = { "use_edit_page_button": True, "external_links": "", + "logo_only": False, "github_url": "https://github.com/js2264/momics/", "show_prev_next": False, "search_bar_text": "Search the docs ...", @@ -83,6 +83,8 @@ "footer_start": ["copyright"], "footer_center": ["sphinx-version"], "content_footer_items": ["last-updated"], + "rightsidebar": "false", + "relbarbgcolor": "black", } html_context = { "github_url": "https://github.com/js2264/momics/", @@ -93,11 +95,11 @@ } html_static_path = ["_static"] -autosummary_generate = True - # -- Options for autoapi ------------------------------------------------------- autoapi_type = "python" autoapi_dirs = ["../../src/momics"] +autoapi_ignore = ["*/cli*"] +autoapi_exclude = ["*/cli*"] autoapi_options = [ "members", "undoc-members", diff --git a/docs/source/index.md b/docs/source/index.md index f080a2e..2a9b465 100644 --- a/docs/source/index.md +++ b/docs/source/index.md @@ -18,10 +18,12 @@ The `momics` package aims to facilitate: Follow `momics` development on [GitHub](https://github.com/js2264/momics). ```{toctree} -:caption: Table of content -:maxdepth: 3 +:caption: Contents +:maxdepth: 1 -user_guide/index +user_guide/get-started +user_guide/api +user_guide/cli api/index cli/index ``` diff --git a/docs/source/user_guide/api.md b/docs/source/user_guide/api.md index b02b856..3ce8ff3 100644 --- a/docs/source/user_guide/api.md +++ b/docs/source/user_guide/api.md @@ -1,6 +1,10 @@ # Introduction to `momics` API -## Introduction +```{danger} +This package is still under active development, and we make no promises +about the stability of any specific class, function, etc. +Pin versions if you're worried about breaking changes! +``` The `momics` package provides a Python API for creating and interacting with the `momics` data model. This API is designed to be simple and intuitive, and is built on top of @@ -91,13 +95,13 @@ print(mom.tracks()) ## Querying `momics` repositories -The `momics` package provides a dedicated `MultiRangeQuery` class, +The `momics` package provides a dedicated `MomicsQuery` class, to register query ranges, run queries and export results. ### Registering a query ```python -q = momics.MultiRangeQuery(mom, "I:10-1000") +q = momics.MomicsQuery(mom, "I:10-1000") ``` ### Running a query @@ -126,7 +130,7 @@ q.query_tracks(threads = 4) ### Exporting query results The query results can be coerced into generic bioinformatic data objects and -exported to output files using dedicated methods of the `MultiRangeQuery` class. +exported to output files using dedicated methods of the `MomicsQuery` class. ```python # Coerce queried sequences as a SeqRecord object diff --git a/docs/source/user_guide/get-started.md b/docs/source/user_guide/get-started.md index 5a86745..9a93861 100644 --- a/docs/source/user_guide/get-started.md +++ b/docs/source/user_guide/get-started.md @@ -1,5 +1,11 @@ # Get started with `momics` +```{danger} +This package is still under active development, and we make no promises +about the stability of any specific class, function, etc. +Pin versions if you're worried about breaking changes! +``` + ## Installation With python `3.8` and higher, you can install `momics` from [PyPI](https://pypi.org/project/momics) using `pip`. diff --git a/docs/source/user_guide/index.md b/docs/source/user_guide/index.md deleted file mode 100644 index 5a95689..0000000 --- a/docs/source/user_guide/index.md +++ /dev/null @@ -1,19 +0,0 @@ ---- -html_theme.sidebar_primary.remove: true ---- - -# User guide - -```{danger} -This package is still under active development, and we make no promises -about the stability of any specific class, function, etc. -Pin versions if you're worried about breaking changes! -``` - -```{toctree} -:maxdepth: 3 - -get-started -api -cli -```