diff --git a/docs/Makefile b/doc/Makefile similarity index 69% rename from docs/Makefile rename to doc/Makefile index f2f0753..b638db2 100644 --- a/docs/Makefile +++ b/doc/Makefile @@ -5,23 +5,23 @@ SPHINXOPTS = SPHINXBUILD = sphinx-build PAPER = -BUILDDIR = _build -RELEASE = v0.1 +BUILDDIR = build +BASENAME = $(subst .,,$(subst $() $(),,diffpy.nmf_mapping)) +# User-friendly check for sphinx-build +ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) +$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/) +endif # Internal variables. PAPEROPT_a4 = -D latex_paper_size=a4 PAPEROPT_letter = -D latex_paper_size=letter -ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . +ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source # the i18n builder cannot share the environment and doctrees with the others -I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . +I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source .PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext -DOCREPONAME = .github.io -DOCREPOURL = - - help: @echo "Please use \`make ' where is one of" @echo " html to make standalone HTML files" @@ -35,17 +35,20 @@ help: @echo " epub to make an epub" @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" @echo " latexpdf to make LaTeX files and run them through pdflatex" + @echo " latexpdfja to make LaTeX files and run them through platex/dvipdfmx" @echo " text to make text files" @echo " man to make manual pages" @echo " texinfo to make Texinfo files" @echo " info to make Texinfo files and run them through makeinfo" @echo " gettext to make PO message catalogs" @echo " changes to make an overview of all changed/added/deprecated items" + @echo " xml to make Docutils-native XML files" + @echo " pseudoxml to make pseudoxml-XML files for display purposes" @echo " linkcheck to check all external links for integrity" @echo " doctest to run all doctests embedded in the documentation (if enabled)" clean: - -rm -rf $(BUILDDIR)/* + rm -rf $(BUILDDIR)/* html: $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html @@ -83,17 +86,17 @@ qthelp: @echo @echo "Build finished; now you can run "qcollectiongenerator" with the" \ ".qhcp project file in $(BUILDDIR)/qthelp, like this:" - @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/fief.qhcp" + @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/$(BASENAME).qhcp" @echo "To view the help file:" - @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/fief.qhc" + @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/$(BASENAME).qhc" devhelp: $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp @echo @echo "Build finished." @echo "To view the help file:" - @echo "# mkdir -p $$HOME/.local/share/devhelp/fief" - @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/fief" + @echo "# mkdir -p $$HOME/.local/share/devhelp/$(BASENAME)" + @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/$(BASENAME)" @echo "# devhelp" epub: @@ -114,6 +117,12 @@ latexpdf: $(MAKE) -C $(BUILDDIR)/latex all-pdf @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." +latexpdfja: + $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex + @echo "Running LaTeX files through platex and dvipdfmx..." + $(MAKE) -C $(BUILDDIR)/latex all-pdf-ja + @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." + text: $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text @echo @@ -158,37 +167,28 @@ doctest: @echo "Testing of doctests in the sources finished, look at the " \ "results in $(BUILDDIR)/doctest/output.txt." -push-latest: - cd $(BUILDDIR) && \ - test -d $(DOCREPONAME) || git clone $(DOCREPOURL) $(DOCREPONAME) && \ - cd $(DOCREPONAME) && \ - git pull origin gh-pages && \ - test -d latest || mkdir latest && touch latest/_ && \ - rm -r latest/* && \ - cp -r ../html/* latest/ && \ - git add latest/ && \ - git commit -am "Pushed latest docs at $(date)" && \ - git push - -push-release: - cd $(BUILDDIR) && \ - test -d $(DOCREPONAME) || git clone $(DOCREPOURL) $(DOCREPONAME) && \ - cd $(DOCREPONAME) && \ - git pull origin gh-pages && \ - test -d $(RELEASE) || mkdir $(RELEASE) && touch $(RELEASE)/_ && \ - rm -r $(RELEASE)/* && \ - cp -r ../html/* $(RELEASE)/ && \ - git add $(RELEASE)/ && \ - git commit -am "Pushed $(RELEASE) docs at $(date)" && \ - git push - -push-root: - cd $(BUILDDIR) && \ - test -d $(DOCREPONAME) || git clone $(DOCREPOURL) $(DOCREPONAME) && \ - cd $(DOCREPONAME) && \ - git pull origin gh-pages && \ - rm -rf libref previous _sources _static *.html *.js *.inv && \ - cp -r ../html/* . && \ - git add . && \ - git commit -am "Pushed root-level docs at $(date)" && \ - git push +# Manual publishing to the gh-pages branch + +GITREPOPATH = $(shell cd $(CURDIR) && git rev-parse --git-dir) +GITREMOTE = origin +GITREMOTEURL = $(shell git config --get remote.$(GITREMOTE).url) +GITLASTCOMMIT = $(shell git rev-parse --short HEAD) + +publish: + @test -d build/html || \ + ( echo >&2 "Run 'make html' first!"; false ) + git show-ref --verify --quiet refs/heads/gh-pages || \ + git branch --track gh-pages $(GITREMOTE)/gh-pages + test -d build/gh-pages || \ + git clone -s -b gh-pages $(GITREPOPATH) build/gh-pages + cd build/gh-pages && \ + git pull $(GITREMOTEURL) gh-pages + rsync -acv --delete --exclude=.git --exclude=.rsync-exclude \ + --exclude-from=build/gh-pages/.rsync-exclude \ + --link-dest=$(CURDIR)/build/html build/html/ build/gh-pages/ + cd build/gh-pages && \ + git add --all . && \ + git diff --cached --quiet || \ + git commit -m "Sync with the source at $(GITLASTCOMMIT)." + cd build/gh-pages && \ + git push origin gh-pages diff --git a/docs/examples/NMFBatching.ipynb b/doc/examples/NMFBatching.ipynb similarity index 100% rename from docs/examples/NMFBatching.ipynb rename to doc/examples/NMFBatching.ipynb diff --git a/docs/examples/data/edited.INP b/doc/examples/data/edited.INP similarity index 100% rename from docs/examples/data/edited.INP rename to doc/examples/data/edited.INP diff --git a/docs/examples/data/example.INP b/doc/examples/data/example.INP similarity index 100% rename from docs/examples/data/example.INP rename to doc/examples/data/example.INP diff --git a/docs/examples/data/example_phases/LiO2.cif b/doc/examples/data/example_phases/LiO2.cif similarity index 100% rename from docs/examples/data/example_phases/LiO2.cif rename to doc/examples/data/example_phases/LiO2.cif diff --git a/docs/examples/data/example_phases/RuO2_tetragonal.cif b/doc/examples/data/example_phases/RuO2_tetragonal.cif similarity index 100% rename from docs/examples/data/example_phases/RuO2_tetragonal.cif rename to doc/examples/data/example_phases/RuO2_tetragonal.cif diff --git a/docs/examples/data/example_phases/Ru_mp-8639_conventional_standard.cif b/doc/examples/data/example_phases/Ru_mp-8639_conventional_standard.cif similarity index 100% rename from docs/examples/data/example_phases/Ru_mp-8639_conventional_standard.cif rename to doc/examples/data/example_phases/Ru_mp-8639_conventional_standard.cif diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic0.gr b/doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic0.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic0.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic0.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic1.gr b/doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic1.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic1.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic1.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic2.gr b/doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic2.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic2.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic2.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic3.gr b/doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic3.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic3.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic3.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic4.gr b/doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic4.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_0/synthetic4.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_0/synthetic4.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic10.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic10.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic10.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic10.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic11.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic11.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic11.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic11.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic12.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic12.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic12.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic12.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic5.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic5.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic5.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic5.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic6.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic6.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic6.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic6.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic7.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic7.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic7.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic7.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic8.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic8.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic8.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic8.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic9.gr b/doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic9.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_1/synthetic9.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_1/synthetic9.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic13.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic13.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic13.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic13.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic14.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic14.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic14.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic14.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic15.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic15.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic15.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic15.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic16.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic16.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic16.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic16.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic17.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic17.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic17.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic17.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic18.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic18.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic18.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic18.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic19.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic19.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic19.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic19.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic20.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic20.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic20.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic20.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic21.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic21.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic21.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic21.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic22.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic22.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic22.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic22.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic23.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic23.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic23.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic23.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic24.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic24.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic24.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic24.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic25.gr b/doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic25.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_2/synthetic25.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_2/synthetic25.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic26.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic26.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic26.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic26.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic27.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic27.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic27.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic27.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic28.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic28.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic28.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic28.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic29.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic29.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic29.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic29.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic30.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic30.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic30.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic30.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic31.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic31.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic31.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic31.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic32.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic32.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic32.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic32.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic33.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic33.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic33.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic33.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic34.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic34.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic34.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic34.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic35.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic35.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic35.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic35.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic36.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic36.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic36.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic36.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic37.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic37.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic37.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic37.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic38.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic38.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic38.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic38.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic39.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic39.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic39.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic39.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic40.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic40.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic40.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic40.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic41.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic41.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic41.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic41.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic42.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic42.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic42.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic42.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic43.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic43.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic43.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic43.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic44.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic44.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic44.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic44.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic45.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic45.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic45.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic45.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic46.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic46.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic46.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic46.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic47.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic47.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic47.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic47.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic48.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic48.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic48.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic48.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic49.gr b/doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic49.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/batch_3/synthetic49.gr rename to doc/examples/data/synthetic_r_vs_gr/batch_3/synthetic49.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic0.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic0.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic0.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic0.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic1.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic1.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic1.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic1.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic10.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic10.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic10.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic10.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic11.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic11.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic11.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic11.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic12.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic12.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic12.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic12.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic13.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic13.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic13.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic13.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic14.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic14.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic14.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic14.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic15.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic15.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic15.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic15.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic16.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic16.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic16.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic16.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic17.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic17.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic17.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic17.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic18.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic18.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic18.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic18.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic19.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic19.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic19.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic19.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic2.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic2.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic2.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic2.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic20.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic20.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic20.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic20.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic21.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic21.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic21.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic21.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic22.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic22.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic22.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic22.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic23.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic23.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic23.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic23.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic24.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic24.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic24.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic24.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic25.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic25.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic25.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic25.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic26.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic26.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic26.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic26.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic27.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic27.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic27.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic27.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic28.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic28.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic28.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic28.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic29.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic29.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic29.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic29.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic3.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic3.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic3.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic3.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic30.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic30.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic30.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic30.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic31.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic31.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic31.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic31.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic32.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic32.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic32.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic32.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic33.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic33.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic33.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic33.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic34.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic34.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic34.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic34.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic35.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic35.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic35.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic35.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic36.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic36.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic36.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic36.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic37.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic37.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic37.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic37.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic38.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic38.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic38.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic38.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic39.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic39.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic39.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic39.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic4.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic4.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic4.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic4.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic40.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic40.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic40.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic40.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic41.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic41.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic41.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic41.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic42.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic42.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic42.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic42.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic43.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic43.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic43.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic43.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic44.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic44.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic44.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic44.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic45.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic45.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic45.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic45.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic46.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic46.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic46.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic46.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic47.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic47.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic47.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic47.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic48.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic48.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic48.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic48.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic49.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic49.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic49.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic49.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic5.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic5.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic5.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic5.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic6.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic6.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic6.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic6.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic7.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic7.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic7.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic7.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic8.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic8.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic8.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic8.gr diff --git a/docs/examples/data/synthetic_r_vs_gr/synthetic9.gr b/doc/examples/data/synthetic_r_vs_gr/synthetic9.gr similarity index 100% rename from docs/examples/data/synthetic_r_vs_gr/synthetic9.gr rename to doc/examples/data/synthetic_r_vs_gr/synthetic9.gr diff --git a/doc/make.bat b/doc/make.bat new file mode 100644 index 0000000..ac53d5b --- /dev/null +++ b/doc/make.bat @@ -0,0 +1,36 @@ +@ECHO OFF + +pushd %~dp0 + +REM Command file for Sphinx documentation + +if "%SPHINXBUILD%" == "" ( + set SPHINXBUILD=sphinx-build +) +set SOURCEDIR=source +set BUILDDIR=build +set SPHINXPROJ=PackagingScientificPython + +if "%1" == "" goto help + +%SPHINXBUILD% >NUL 2>NUL +if errorlevel 9009 ( + echo. + echo.The 'sphinx-build' command was not found. Make sure you have Sphinx + echo.installed, then set the SPHINXBUILD environment variable to point + echo.to the full path of the 'sphinx-build' executable. Alternatively you + echo.may add the Sphinx directory to PATH. + echo. + echo.If you don't have Sphinx installed, grab it from + echo.http://sphinx-doc.org/ + exit /b 1 +) + +%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% +goto end + +:help +%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% + +:end +popd diff --git a/doc/source/_static/.placeholder b/doc/source/_static/.placeholder new file mode 100644 index 0000000..e69de29 diff --git a/doc/source/api/diffpy.nmf_mapping.example_package.rst b/doc/source/api/diffpy.nmf_mapping.example_package.rst new file mode 100644 index 0000000..da17a67 --- /dev/null +++ b/doc/source/api/diffpy.nmf_mapping.example_package.rst @@ -0,0 +1,31 @@ +.. _example_package documentation: + +|title| +======= + +.. |title| replace:: diffpy.nmf_mapping.example_package package + +.. automodule:: diffpy.nmf_mapping.example_package + :members: + :undoc-members: + :show-inheritance: + +|foo| +----- + +.. |foo| replace:: diffpy.nmf_mapping.example_package.foo module + +.. automodule:: diffpy.nmf_mapping.example_package.foo + :members: + :undoc-members: + :show-inheritance: + +|bar| +----- + +.. |bar| replace:: diffpy.nmf_mapping.example_package.bar module + +.. automodule:: diffpy.nmf_mapping.example_package.foo + :members: + :undoc-members: + :show-inheritance: diff --git a/doc/source/api/diffpy.nmf_mapping.rst b/doc/source/api/diffpy.nmf_mapping.rst new file mode 100644 index 0000000..0f03d4b --- /dev/null +++ b/doc/source/api/diffpy.nmf_mapping.rst @@ -0,0 +1,30 @@ +:tocdepth: -1 + +|title| +======= + +.. |title| replace:: diffpy.nmf_mapping package + +.. automodule:: diffpy.nmf_mapping + :members: + :undoc-members: + :show-inheritance: + +Subpackages +----------- + +.. toctree:: + diffpy.nmf_mapping.example_package + +Submodules +---------- + +|module| +-------- + +.. |module| replace:: diffpy.nmf_mapping.example_submodule module + +.. automodule:: diffpy.nmf_mapping.example_submodule + :members: + :undoc-members: + :show-inheritance: diff --git a/doc/source/conf.py b/doc/source/conf.py new file mode 100644 index 0000000..4280239 --- /dev/null +++ b/doc/source/conf.py @@ -0,0 +1,289 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# +# diffpy.nmf_mapping documentation build configuration file, created by +# sphinx-quickstart on Thu Jan 30 15:49:41 2014. +# +# This file is execfile()d with the current directory set to its +# containing dir. +# +# Note that not all possible configuration values are present in this +# autogenerated file. +# +# All configuration values have a default; values that are commented out +# serve to show the default. + +import sys +import time +from importlib.metadata import version +from pathlib import Path + +# 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 Path().resolve() to make it absolute, like shown here. +# sys.path.insert(0, str(Path(".").resolve())) +sys.path.insert(0, str(Path("../..").resolve())) +sys.path.insert(0, str(Path("../../src").resolve())) + +# abbreviations +ab_authors = "Billinge Group members and community contributors" + +# -- General configuration ------------------------------------------------ + +# If your documentation needs a minimal Sphinx version, state it here. +# needs_sphinx = '1.0' + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom +# ones. +extensions = [ + "sphinx.ext.autodoc", + "sphinx.ext.napoleon", + "sphinx.ext.todo", + "sphinx.ext.viewcode", + "sphinx.ext.intersphinx", + "sphinx_rtd_theme", + "m2r", +] + +# Add any paths that contain templates here, relative to this directory. +templates_path = ["_templates"] + +# The suffix(es) of source filenames. +# You can specify multiple suffix as a list of string: +# +source_suffix = [".rst", ".md"] + +# The encoding of source files. +# source_encoding = 'utf-8-sig' + +# The master toctree document. +master_doc = "index" + +# General information about the project. +project = "diffpy.nmf_mapping" +copyright = "2023-%Y, The Trustees of Columbia University in the City of New York" + +# The version info for the project you're documenting, acts as replacement for +# |version| and |release|, also used in various other places throughout the +# built documents. + +fullversion = version(project) +# The short X.Y version. +version = "".join(fullversion.split(".post")[:1]) +# The full version, including alpha/beta/rc tags. +release = fullversion + +# The language for content autogenerated by Sphinx. Refer to documentation +# for a list of supported languages. +# language = None + +# There are two options for replacing |today|: either, you set today to some +# non-false value, then it is used: +# today = '' +today = time.strftime("%B %d, %Y", time.localtime()) +year = today.split()[-1] +# Else, today_fmt is used as the format for a strftime call. +# today_fmt = '%B %d, %Y' +# substitute YEAR in the copyright string +copyright = copyright.replace("%Y", year) + +# List of patterns, relative to source directory, that match files and +# directories to ignore when looking for source files. +exclude_patterns = ["build"] + +# The reST default role (used for this markup: `text`) to use for all +# documents. +# default_role = None + +# If true, '()' will be appended to :func: etc. cross-reference text. +# add_function_parentheses = True + +# If true, the current module name will be prepended to all description +# unit titles (such as .. function::). +# add_module_names = True + +# If true, sectionauthor and moduleauthor directives will be shown in the +# output. They are ignored by default. +# show_authors = False + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = "sphinx" + +# A list of ignored prefixes for module index sorting. +modindex_common_prefix = ["diffpy.nmf_mapping"] + +# Display all warnings for missing links. +nitpicky = True + +# -- 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 = "sphinx_rtd_theme" + +# Theme options are theme-specific and customize the look and feel of a theme +# further. For a list of options available for each theme, see the +# documentation. +# +html_theme_options = { + "navigation_with_keys": "true", +} + +# Add any paths that contain custom themes here, relative to this directory. +# html_theme_path = [] + +# The name for this set of Sphinx documents. If None, it defaults to +# " v documentation". +# html_title = None + +# A shorter title for the navigation bar. Default is the same as html_title. +# html_short_title = None + +# The name of an image file (relative to this directory) to place at the top +# of the sidebar. +# html_logo = None + +# The name of an image file (within the static path) to use as favicon of the +# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 +# pixels large. +# html_favicon = None + +# 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'] + +# Add any extra paths that contain custom files (such as robots.txt or +# .htaccess) here, relative to this directory. These files are copied +# directly to the root of the documentation. +# html_extra_path = [] + +# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, +# using the given strftime format. +# html_last_updated_fmt = '%b %d, %Y' + +# If true, SmartyPants will be used to convert quotes and dashes to +# typographically correct entities. +# html_use_smartypants = True + +# Custom sidebar templates, maps document names to template names. +# html_sidebars = {} + +# Additional templates that should be rendered to pages, maps page names to +# template names. +# html_additional_pages = {} + +# If false, no module index is generated. +# html_domain_indices = True + +# If false, no index is generated. +# html_use_index = True + +# If true, the index is split into individual pages for each letter. +# html_split_index = False + +# If true, links to the reST sources are added to the pages. +# html_show_sourcelink = True + +# If true, "Created using Sphinx" is shown in the HTML footer. Default is True. +# html_show_sphinx = True + +# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. +# html_show_copyright = True + +# If true, an OpenSearch description file will be output, and all pages will +# contain a tag referring to it. The value of this option must be the +# base URL from which the finished HTML is served. +# html_use_opensearch = '' + +# This is the file name suffix for HTML files (e.g. ".xhtml"). +# html_file_suffix = None + +# Output file base name for HTML help builder. +basename = "diffpy.nmf_mapping".replace(" ", "").replace(".", "") +htmlhelp_basename = basename + "doc" + + +# -- Options for LaTeX output --------------------------------------------- + +latex_elements = { + # The paper size ('letterpaper' or 'a4paper'). + # 'papersize': 'letterpaper', + # The font size ('10pt', '11pt' or '12pt'). + # 'pointsize': '10pt', + # Additional stuff for the LaTeX preamble. + # 'preamble': '', +} + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, +# author, documentclass [howto, manual, or own class]). +latex_documents = [ + ("index", "diffpy.nmf_mapping.tex", "diffpy.nmf_mapping Documentation", ab_authors, "manual"), +] + +# The name of an image file (relative to this directory) to place at the top of +# the title page. +# latex_logo = None + +# For "manual" documents, if this is true, then toplevel headings are parts, +# not chapters. +# latex_use_parts = False + +# If true, show page references after internal links. +# latex_show_pagerefs = False + +# If true, show URL addresses after external links. +# latex_show_urls = False + +# Documents to append as an appendix to all manuals. +# latex_appendices = [] + +# If false, no module index is generated. +# latex_domain_indices = True + + +# -- Options for manual page output --------------------------------------- + +# One entry per manual page. List of tuples +# (source start file, name, description, authors, manual section). +man_pages = [("index", "diffpy.nmf_mapping", "diffpy.nmf_mapping Documentation", ab_authors, 1)] + +# If true, show URL addresses after external links. +# man_show_urls = False + + +# -- Options for Texinfo output ------------------------------------------- + +# Grouping the document tree into Texinfo files. List of tuples +# (source start file, target name, title, author, +# dir menu entry, description, category) +texinfo_documents = [ + ( + "index", + "diffpy.nmf_mapping", + "diffpy.nmf_mapping Documentation", + ab_authors, + "diffpy.nmf_mapping", + "One line description of project.", + "Miscellaneous", + ), +] + +# Documents to append as an appendix to all manuals. +# texinfo_appendices = [] + +# If false, no module index is generated. +# texinfo_domain_indices = True + +# How to display URL addresses: 'footnote', 'no', or 'inline'. +# texinfo_show_urls = 'footnote' + +# If true, do not generate a @detailmenu in the "Top" node's menu. +# texinfo_no_detailmenu = False + + +# Example configuration for intersphinx: refer to the Python standard library. +# intersphinx_mapping = {'http://docs.python.org/': None} diff --git a/doc/source/index.rst b/doc/source/index.rst new file mode 100644 index 0000000..8ac8e89 --- /dev/null +++ b/doc/source/index.rst @@ -0,0 +1,44 @@ +####### +|title| +####### + +.. |title| replace:: diffpy.nmf_mapping documentation + +diffpy.nmf_mapping - Run NMF analysis on PDF and XRD data. + +| Software version |release|. +| Last updated |today|. + +======= +Authors +======= + +diffpy.nmf_mapping is developed by Billinge Group +and its community contributors. + +For a detailed list of contributors see +https://github.com/diffpy/diffpy.nmf_mapping/graphs/contributors. + +============ +Installation +============ + +See the `README `_ +file included with the distribution. + +================= +Table of contents +================= +.. toctree:: + :titlesonly: + + license + release + Package API + +======= +Indices +======= + +* :ref:`genindex` +* :ref:`search` diff --git a/doc/source/license.rst b/doc/source/license.rst new file mode 100644 index 0000000..cc67702 --- /dev/null +++ b/doc/source/license.rst @@ -0,0 +1,39 @@ +:tocdepth: -1 + +.. index:: license + +License +####### + +OPEN SOURCE LICENSE AGREEMENT +============================= +BSD 3-Clause License + +Copyright (c) 2022-2024, The Trustees of Columbia University in +the City of New York. +All Rights Reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/doc/source/release.rst b/doc/source/release.rst new file mode 100644 index 0000000..27cd0cc --- /dev/null +++ b/doc/source/release.rst @@ -0,0 +1,5 @@ +:tocdepth: -1 + +.. index:: release notes + +.. include:: ../../CHANGELOG.rst diff --git a/docs/make.bat b/docs/make.bat deleted file mode 100644 index ec0e4c3..0000000 --- a/docs/make.bat +++ /dev/null @@ -1,190 +0,0 @@ -@ECHO OFF - -REM Command file for Sphinx documentation - -if "%SPHINXBUILD%" == "" ( - set SPHINXBUILD=sphinx-build -) -set BUILDDIR=_build -set ALLSPHINXOPTS=-d %BUILDDIR%/doctrees %SPHINXOPTS% . -set I18NSPHINXOPTS=%SPHINXOPTS% . -if NOT "%PAPER%" == "" ( - set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS% - set I18NSPHINXOPTS=-D latex_paper_size=%PAPER% %I18NSPHINXOPTS% -) - -if "%1" == "" goto help - -if "%1" == "help" ( - :help - echo.Please use `make ^` where ^ is one of - echo. html to make standalone HTML files - echo. dirhtml to make HTML files named index.html in directories - echo. singlehtml to make a single large HTML file - echo. pickle to make pickle files - echo. json to make JSON files - echo. htmlhelp to make HTML files and a HTML help project - echo. qthelp to make HTML files and a qthelp project - echo. devhelp to make HTML files and a Devhelp project - echo. epub to make an epub - echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter - echo. text to make text files - echo. man to make manual pages - echo. texinfo to make Texinfo files - echo. gettext to make PO message catalogs - echo. changes to make an overview over all changed/added/deprecated items - echo. linkcheck to check all external links for integrity - echo. doctest to run all doctests embedded in the documentation if enabled - goto end -) - -if "%1" == "clean" ( - for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i - del /q /s %BUILDDIR%\* - goto end -) - -if "%1" == "html" ( - %SPHINXBUILD% -b html %ALLSPHINXOPTS% %BUILDDIR%/html - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The HTML pages are in %BUILDDIR%/html. - goto end -) - -if "%1" == "dirhtml" ( - %SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% %BUILDDIR%/dirhtml - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The HTML pages are in %BUILDDIR%/dirhtml. - goto end -) - -if "%1" == "singlehtml" ( - %SPHINXBUILD% -b singlehtml %ALLSPHINXOPTS% %BUILDDIR%/singlehtml - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The HTML pages are in %BUILDDIR%/singlehtml. - goto end -) - -if "%1" == "pickle" ( - %SPHINXBUILD% -b pickle %ALLSPHINXOPTS% %BUILDDIR%/pickle - if errorlevel 1 exit /b 1 - echo. - echo.Build finished; now you can process the pickle files. - goto end -) - -if "%1" == "json" ( - %SPHINXBUILD% -b json %ALLSPHINXOPTS% %BUILDDIR%/json - if errorlevel 1 exit /b 1 - echo. - echo.Build finished; now you can process the JSON files. - goto end -) - -if "%1" == "htmlhelp" ( - %SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% %BUILDDIR%/htmlhelp - if errorlevel 1 exit /b 1 - echo. - echo.Build finished; now you can run HTML Help Workshop with the ^ -.hhp project file in %BUILDDIR%/htmlhelp. - goto end -) - -if "%1" == "qthelp" ( - %SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% %BUILDDIR%/qthelp - if errorlevel 1 exit /b 1 - echo. - echo.Build finished; now you can run "qcollectiongenerator" with the ^ -.qhcp project file in %BUILDDIR%/qthelp, like this: - echo.^> qcollectiongenerator %BUILDDIR%\qthelp\fief.qhcp - echo.To view the help file: - echo.^> assistant -collectionFile %BUILDDIR%\qthelp\fief.ghc - goto end -) - -if "%1" == "devhelp" ( - %SPHINXBUILD% -b devhelp %ALLSPHINXOPTS% %BUILDDIR%/devhelp - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. - goto end -) - -if "%1" == "epub" ( - %SPHINXBUILD% -b epub %ALLSPHINXOPTS% %BUILDDIR%/epub - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The epub file is in %BUILDDIR%/epub. - goto end -) - -if "%1" == "latex" ( - %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex - if errorlevel 1 exit /b 1 - echo. - echo.Build finished; the LaTeX files are in %BUILDDIR%/latex. - goto end -) - -if "%1" == "text" ( - %SPHINXBUILD% -b text %ALLSPHINXOPTS% %BUILDDIR%/text - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The text files are in %BUILDDIR%/text. - goto end -) - -if "%1" == "man" ( - %SPHINXBUILD% -b man %ALLSPHINXOPTS% %BUILDDIR%/man - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The manual pages are in %BUILDDIR%/man. - goto end -) - -if "%1" == "texinfo" ( - %SPHINXBUILD% -b texinfo %ALLSPHINXOPTS% %BUILDDIR%/texinfo - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The Texinfo files are in %BUILDDIR%/texinfo. - goto end -) - -if "%1" == "gettext" ( - %SPHINXBUILD% -b gettext %I18NSPHINXOPTS% %BUILDDIR%/locale - if errorlevel 1 exit /b 1 - echo. - echo.Build finished. The message catalogs are in %BUILDDIR%/locale. - goto end -) - -if "%1" == "changes" ( - %SPHINXBUILD% -b changes %ALLSPHINXOPTS% %BUILDDIR%/changes - if errorlevel 1 exit /b 1 - echo. - echo.The overview file is in %BUILDDIR%/changes. - goto end -) - -if "%1" == "linkcheck" ( - %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% %BUILDDIR%/linkcheck - if errorlevel 1 exit /b 1 - echo. - echo.Link check complete; look for any errors in the above output ^ -or in %BUILDDIR%/linkcheck/output.txt. - goto end -) - -if "%1" == "doctest" ( - %SPHINXBUILD% -b doctest %ALLSPHINXOPTS% %BUILDDIR%/doctest - if errorlevel 1 exit /b 1 - echo. - echo.Testing of doctests in the sources finished, look at the ^ -results in %BUILDDIR%/doctest/output.txt. - goto end -) - -:end