Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Makefile and config file for Sphinx, nbsphinx (Add Sphinx docs - Part 3) #97

Closed
wants to merge 22 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
_build
.ipynb_checkpoints/
download-any-bam-file/Aligned.sortedByCoord.out.bam
download-smartseq2-matrix-scanpy/matrix.results
download-smartseq2-matrix-scanpy/matrix.tsv
download-smartseq2-matrix-scanpy/matrix2.results
download-smartseq2-matrix-scanpy/matrix2.tsv
explore-hca-dataset-scanpy-may-2019/pancreas.loom
explore-hca-dataset-scanpy/pancreas.loom
36 changes: 36 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
include common.mk

# Minimal makefile for Sphinx documentation
#
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = .
BUILDDIR = _build

.PHONY: help Makefile

# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

refresh_all_requirements:
@echo '' >| requirements-docs.txt
@if [ $$(uname -s) == "Darwin" ]; then sleep 1; fi # this is require because Darwin HFS+ only has second-resolution for timestamps.
@touch requirements-docs.txt.in
@$(MAKE) requirements-docs.txt

requirements-docs.txt : %.txt : %.txt.in
[ ! -e .requirements-env ] || exit 1
virtualenv -p $(shell which python3) .$<-env
.$<-env/bin/pip install -r $@
.$<-env/bin/pip install -r $<
echo "# You should not edit this file directly. Instead, you should edit $<." >| $@
.$<-env/bin/pip freeze >> $@
rm -rf .$<-env

html: Makefile
@$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(0)

# to make sphinx documentation in any other format, use the command sphinx-build -b <format>
3 changes: 3 additions & 0 deletions common.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ifeq ($(shell which pandoc),)
$(error Please install pandoc using "apt-get install pandoc" or "brew install pandoc")
endif
55 changes: 55 additions & 0 deletions conf.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html

# -- Path setup --------------------------------------------------------------

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
# import os
# import sys
# sys.path.insert(0, os.path.abspath('.'))


# -- Project information -----------------------------------------------------

project = 'Data Consumer Vignettes'
copyright = '2019, Human Cell Atlas'
author = 'Human Cell Atlas'


# -- General configuration ---------------------------------------------------

# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'nbsphinx'
]

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = [
'vp', 'dcv', '_src', '_build', 'Thumbs.db', '.DS_Store', '**.ipynb_checkpoints'
]


# -- Options for HTML output -------------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'alabaster'

# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
6 changes: 6 additions & 0 deletions download-10x-liver/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Download Data for All Liver Cells Sequenced with 10x

In this notebook, we cover how to search the Human Cell Atlas Data Store (DSS) for bundles containing liver cells
that were sequenced with 10x, and download all of the data that is found.

See the [notebook](download-10x-liver.ipynb).
Loading