From c14a8c6de0eb69cbbdb5d282619fca5f6fcd6c45 Mon Sep 17 00:00:00 2001
From: nhertz <nhertz@nrao.edu>
Date: Wed, 18 Nov 2020 10:33:10 -0700
Subject: [PATCH] Added new clean target; added gen_rst target, which will
 re-generate RST files from our API

---
 docs/Makefile | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/docs/Makefile b/docs/Makefile
index af23b91da..6c3277311 100644
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -12,7 +12,10 @@ BUILDDIR      = _build
 help:
 	@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
 
-.PHONY: help Makefile
+.PHONY: help Makefile gen_rst env_setup clean
+
+gen_rst:
+	find .. -name src -exec sphinx-apidoc -e -M -f --ext-autodoc -o source/api {} \;
 
 env_setup:
 	pip3 install -r requirements.txt
@@ -21,3 +24,6 @@ env_setup:
 # "make mode" option.  $(O) is meant as a shortcut for $(SPHINXOPTS).
 %: Makefile env_setup
 	@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
+
+clean:
+	rm -rf $(BUILDDIR)
-- 
GitLab