From 0d64d6a5b662b63dbe3d5491156699c1a1d2936a Mon Sep 17 00:00:00 2001 From: Darko Poljak Date: Thu, 30 Jun 2016 15:05:26 +0200 Subject: [PATCH] docs/man -> docs/src and update Makefile and build-helper. --- .gitignore | 13 +++---- Makefile | 38 +++++++++---------- bin/build-helper | 4 +- bin/build-helper.freebsd | 4 +- docs/{man => src}/Makefile | 0 docs/{man => src}/cdist-best-practice.rst | 0 docs/{man => src}/cdist-bootstrap.rst | 0 docs/{man => src}/cdist-explorer.rst | 0 docs/{man => src}/cdist-features.rst | 0 docs/{man => src}/cdist-hacker.rst | 0 docs/{man => src}/cdist-install.rst | 0 docs/{man => src}/cdist-intro.rst | 0 docs/{man => src}/cdist-logo.png | Bin docs/{man => src}/cdist-manifest.rst | 0 docs/{man => src}/cdist-messaging.rst | 0 docs/{man => src}/cdist-os.rst | 0 docs/{man => src}/cdist-quickstart.rst | 0 docs/{man => src}/cdist-reference.rst.sh | 0 docs/{man => src}/cdist-remote-exec-copy.rst | 0 docs/{man => src}/cdist-stages.rst | 0 docs/{man => src}/cdist-support.rst | 0 docs/{man => src}/cdist-troubleshooting.rst | 0 docs/{man => src}/cdist-type.rst | 0 docs/{man => src}/cdist-types.rst | 0 docs/{man => src}/cdist-update.rst | 0 docs/{man => src}/cdist-why.rst | 0 docs/{man => src}/conf.py | 0 docs/{man => src}/index.rst | 0 docs/{man => src}/man1/cdist.rst | 0 docs/{man => src}/man7/.gitignore | 0 30 files changed, 28 insertions(+), 31 deletions(-) rename docs/{man => src}/Makefile (100%) rename docs/{man => src}/cdist-best-practice.rst (100%) rename docs/{man => src}/cdist-bootstrap.rst (100%) rename docs/{man => src}/cdist-explorer.rst (100%) rename docs/{man => src}/cdist-features.rst (100%) rename docs/{man => src}/cdist-hacker.rst (100%) rename docs/{man => src}/cdist-install.rst (100%) rename docs/{man => src}/cdist-intro.rst (100%) rename docs/{man => src}/cdist-logo.png (100%) rename docs/{man => src}/cdist-manifest.rst (100%) rename docs/{man => src}/cdist-messaging.rst (100%) rename docs/{man => src}/cdist-os.rst (100%) rename docs/{man => src}/cdist-quickstart.rst (100%) rename docs/{man => src}/cdist-reference.rst.sh (100%) rename docs/{man => src}/cdist-remote-exec-copy.rst (100%) rename docs/{man => src}/cdist-stages.rst (100%) rename docs/{man => src}/cdist-support.rst (100%) rename docs/{man => src}/cdist-troubleshooting.rst (100%) rename docs/{man => src}/cdist-type.rst (100%) rename docs/{man => src}/cdist-types.rst (100%) rename docs/{man => src}/cdist-update.rst (100%) rename docs/{man => src}/cdist-why.rst (100%) rename docs/{man => src}/conf.py (100%) rename docs/{man => src}/index.rst (100%) rename docs/{man => src}/man1/cdist.rst (100%) rename docs/{man => src}/man7/.gitignore (100%) diff --git a/.gitignore b/.gitignore index 3bbc4e99..74014aba 100644 --- a/.gitignore +++ b/.gitignore @@ -2,14 +2,11 @@ .*.swp # Ignore generated manpages -docs/man/.marker -docs/man/man1/*.1 -docs/man/man7/*.7 -docs/man/man*/*.html -docs/man/man*/*.xml -docs/man/man*/docbook-xsl.css -docs/man/man7/cdist-type__*.rst -docs/man/cdist-reference.rst +docs/src/.marker +docs/src/man1/*.1 +docs/src/man7/*.7 +docs/src/man7/cdist-type__*.rst +docs/src/cdist-reference.rst # Ignore cdist cache for version control /cache/ diff --git a/Makefile b/Makefile index 9d494f23..7885cf24 100644 --- a/Makefile +++ b/Makefile @@ -20,7 +20,7 @@ helper=./bin/build-helper -MANDIR=docs/man +DOCS_SRC_DIR=docs/src SPEECHDIR=docs/speeches TYPEDIR=cdist/conf/type @@ -36,13 +36,13 @@ CHANGELOG_FILE=docs/changelog PYTHON_VERSION=cdist/version.py -SPHINXM=make -C $(MANDIR) man -SPHINXH=make -C $(MANDIR) html +SPHINXM=make -C $(DOCS_SRC_DIR) man +SPHINXH=make -C $(DOCS_SRC_DIR) html ################################################################################ # Manpages # -MAN1DSTDIR=$(MANDIR)/man1 -MAN7DSTDIR=$(MANDIR)/man7 +MAN1DSTDIR=$(DOCS_SRC_DIR)/man1 +MAN7DSTDIR=$(DOCS_SRC_DIR)/man7 # Manpages #1: Types # Use shell / ls to get complete list - $(TYPEDIR)/*/man.rst does not work @@ -56,26 +56,26 @@ $(MAN7DSTDIR)/cdist-type%.rst: $(TYPEDIR)/%/man.rst ln -sf "../../../$^" $@ # Manpages #2: reference -MANREF=$(MAN7DSTDIR)/cdist-reference.rst -MANREFSH=$(MANDIR)/cdist-reference.rst.sh +DOCSREF=$(MAN7DSTDIR)/cdist-reference.rst +DOCSREFSH=$(DOCS_SRC_DIR)/cdist-reference.rst.sh -$(MANREF): $(MANREFSH) - $(MANREFSH) +$(DOCSREF): $(DOCSREFSH) + $(DOCSREFSH) # Manpages #3: generic part -mansphinxman: $(MANTYPES) $(MANREF) $(PYTHON_VERSION) +sphinxman: $(MANTYPES) $(DOCSREF) $(PYTHON_VERSION) $(SPHINXM) -mansphinxhtml: $(MANTYPES) $(MANREF) $(PYTHON_VERSION) +sphinxhtml: $(MANTYPES) $(DOCSREF) $(PYTHON_VERSION) $(SPHINXH) -man: mansphinxman mansphinxhtml +docs: sphinxman sphinxhtml # Manpages #5: release part MANWEBDIR=$(WEBBASE)/man/$(CHANGELOG_VERSION) MANBUILDDIR=docs/dist/html -man-dist: man +docs-dist: man rm -rf "${MANWEBDIR}" mkdir -p "${MANWEBDIR}" # mkdir -p "${MANWEBDIR}/man1" "${MANWEBDIR}/man7" @@ -102,10 +102,10 @@ $(DOTMAN7DSTDIR)/cdist-type%.rst: $(DOTTYPEDIR)/%/man.rst ln -sf "$^" $@ # Manpages #3: generic part -dotmansphinxman: $(DOTMANTYPES) +dotsphinxman: $(DOTMANTYPES) $(SPHINXM) -dotman: dotmansphinxman +dotman: dotsphinxman ################################################################################ @@ -147,7 +147,7 @@ web-doc: web-dist: web-blog web-doc -web-pub: web-dist man-dist speeches-dist +web-pub: web-dist docs-dist speeches-dist cd "${WEBDIR}" && make pub web-release-all: man-latest-link @@ -212,12 +212,12 @@ release: # clean: - rm -f $(MANDIR)/cdist-reference.rst + rm -f $(DOCS_SRC_DIR)/cdist-reference.rst - find "$(MANDIR)" -mindepth 2 -type l \ + find "$(DOCS_SRC_DIR)" -mindepth 2 -type l \ | xargs rm -f - make -C $(MANDIR) clean + make -C $(DOCS_SRC_DIR) clean find * -name __pycache__ | xargs rm -rf diff --git a/bin/build-helper b/bin/build-helper index 31789a2e..8f228697 100755 --- a/bin/build-helper +++ b/bin/build-helper @@ -206,8 +206,8 @@ eof "$0" check-date "$0" check-unittest - # Generate man pages (indirect check if they build) - make man + # Generate documentation (man and html) + make docs # Generate speeches (indirect check if they build) make speeches diff --git a/bin/build-helper.freebsd b/bin/build-helper.freebsd index 01d86a10..02e71586 100755 --- a/bin/build-helper.freebsd +++ b/bin/build-helper.freebsd @@ -241,8 +241,8 @@ eof "$0" check-date "$0" check-unittest - # Generate man pages (indirect check if they build) - make helper=${helper} WEBDIR=${WEBDIR} man + # Generate documentation (man and html) + make helper=${helper} WEBDIR=${WEBDIR} docs # Generate speeches (indirect check if they build) make helper=${helper} WEBDIR=${WEBDIR} speeches diff --git a/docs/man/Makefile b/docs/src/Makefile similarity index 100% rename from docs/man/Makefile rename to docs/src/Makefile diff --git a/docs/man/cdist-best-practice.rst b/docs/src/cdist-best-practice.rst similarity index 100% rename from docs/man/cdist-best-practice.rst rename to docs/src/cdist-best-practice.rst diff --git a/docs/man/cdist-bootstrap.rst b/docs/src/cdist-bootstrap.rst similarity index 100% rename from docs/man/cdist-bootstrap.rst rename to docs/src/cdist-bootstrap.rst diff --git a/docs/man/cdist-explorer.rst b/docs/src/cdist-explorer.rst similarity index 100% rename from docs/man/cdist-explorer.rst rename to docs/src/cdist-explorer.rst diff --git a/docs/man/cdist-features.rst b/docs/src/cdist-features.rst similarity index 100% rename from docs/man/cdist-features.rst rename to docs/src/cdist-features.rst diff --git a/docs/man/cdist-hacker.rst b/docs/src/cdist-hacker.rst similarity index 100% rename from docs/man/cdist-hacker.rst rename to docs/src/cdist-hacker.rst diff --git a/docs/man/cdist-install.rst b/docs/src/cdist-install.rst similarity index 100% rename from docs/man/cdist-install.rst rename to docs/src/cdist-install.rst diff --git a/docs/man/cdist-intro.rst b/docs/src/cdist-intro.rst similarity index 100% rename from docs/man/cdist-intro.rst rename to docs/src/cdist-intro.rst diff --git a/docs/man/cdist-logo.png b/docs/src/cdist-logo.png similarity index 100% rename from docs/man/cdist-logo.png rename to docs/src/cdist-logo.png diff --git a/docs/man/cdist-manifest.rst b/docs/src/cdist-manifest.rst similarity index 100% rename from docs/man/cdist-manifest.rst rename to docs/src/cdist-manifest.rst diff --git a/docs/man/cdist-messaging.rst b/docs/src/cdist-messaging.rst similarity index 100% rename from docs/man/cdist-messaging.rst rename to docs/src/cdist-messaging.rst diff --git a/docs/man/cdist-os.rst b/docs/src/cdist-os.rst similarity index 100% rename from docs/man/cdist-os.rst rename to docs/src/cdist-os.rst diff --git a/docs/man/cdist-quickstart.rst b/docs/src/cdist-quickstart.rst similarity index 100% rename from docs/man/cdist-quickstart.rst rename to docs/src/cdist-quickstart.rst diff --git a/docs/man/cdist-reference.rst.sh b/docs/src/cdist-reference.rst.sh similarity index 100% rename from docs/man/cdist-reference.rst.sh rename to docs/src/cdist-reference.rst.sh diff --git a/docs/man/cdist-remote-exec-copy.rst b/docs/src/cdist-remote-exec-copy.rst similarity index 100% rename from docs/man/cdist-remote-exec-copy.rst rename to docs/src/cdist-remote-exec-copy.rst diff --git a/docs/man/cdist-stages.rst b/docs/src/cdist-stages.rst similarity index 100% rename from docs/man/cdist-stages.rst rename to docs/src/cdist-stages.rst diff --git a/docs/man/cdist-support.rst b/docs/src/cdist-support.rst similarity index 100% rename from docs/man/cdist-support.rst rename to docs/src/cdist-support.rst diff --git a/docs/man/cdist-troubleshooting.rst b/docs/src/cdist-troubleshooting.rst similarity index 100% rename from docs/man/cdist-troubleshooting.rst rename to docs/src/cdist-troubleshooting.rst diff --git a/docs/man/cdist-type.rst b/docs/src/cdist-type.rst similarity index 100% rename from docs/man/cdist-type.rst rename to docs/src/cdist-type.rst diff --git a/docs/man/cdist-types.rst b/docs/src/cdist-types.rst similarity index 100% rename from docs/man/cdist-types.rst rename to docs/src/cdist-types.rst diff --git a/docs/man/cdist-update.rst b/docs/src/cdist-update.rst similarity index 100% rename from docs/man/cdist-update.rst rename to docs/src/cdist-update.rst diff --git a/docs/man/cdist-why.rst b/docs/src/cdist-why.rst similarity index 100% rename from docs/man/cdist-why.rst rename to docs/src/cdist-why.rst diff --git a/docs/man/conf.py b/docs/src/conf.py similarity index 100% rename from docs/man/conf.py rename to docs/src/conf.py diff --git a/docs/man/index.rst b/docs/src/index.rst similarity index 100% rename from docs/man/index.rst rename to docs/src/index.rst diff --git a/docs/man/man1/cdist.rst b/docs/src/man1/cdist.rst similarity index 100% rename from docs/man/man1/cdist.rst rename to docs/src/man1/cdist.rst diff --git a/docs/man/man7/.gitignore b/docs/src/man7/.gitignore similarity index 100% rename from docs/man/man7/.gitignore rename to docs/src/man7/.gitignore