From 4dac520d9875865186cb0cbcdebc3e17579e9e1d Mon Sep 17 00:00:00 2001 From: Darko Poljak Date: Mon, 4 Jul 2016 12:21:01 +0200 Subject: [PATCH] Implement make targets: man, html, docs. --- Makefile | 11 ++++------- docs/src/cdist-install.rst | 21 +++++++++++++++++---- docs/src/man1/cdist.rst | 4 ---- 3 files changed, 21 insertions(+), 15 deletions(-) diff --git a/Makefile b/Makefile index 7885cf24..e1abde88 100644 --- a/Makefile +++ b/Makefile @@ -63,13 +63,13 @@ $(DOCSREF): $(DOCSREFSH) $(DOCSREFSH) # Manpages #3: generic part -sphinxman: $(MANTYPES) $(DOCSREF) $(PYTHON_VERSION) +man: $(MANTYPES) $(DOCSREF) $(PYTHON_VERSION) $(SPHINXM) -sphinxhtml: $(MANTYPES) $(DOCSREF) $(PYTHON_VERSION) +html: $(MANTYPES) $(DOCSREF) $(PYTHON_VERSION) $(SPHINXH) -docs: sphinxman sphinxhtml +docs: man html # Manpages #5: release part MANWEBDIR=$(WEBBASE)/man/$(CHANGELOG_VERSION) @@ -102,12 +102,9 @@ $(DOTMAN7DSTDIR)/cdist-type%.rst: $(DOTTYPEDIR)/%/man.rst ln -sf "$^" $@ # Manpages #3: generic part -dotsphinxman: $(DOTMANTYPES) +dotman: $(DOTMANTYPES) $(SPHINXM) -dotman: dotsphinxman - - ################################################################################ # Speeches # diff --git a/docs/src/cdist-install.rst b/docs/src/cdist-install.rst index a94c12a3..38db1a4e 100644 --- a/docs/src/cdist-install.rst +++ b/docs/src/cdist-install.rst @@ -12,7 +12,7 @@ This is the machine you use to configure the target hosts. * /bin/sh: A posix like shell (for instance bash, dash, zsh) * Python >= 3.2 * SSH client - * sphinx (for building html docs and/or the manpages) + * sphinx (for building html docs and/or the man pages) Target Hosts ~~~~~~~~~~~~ @@ -88,18 +88,31 @@ If you want to use man pages, run: export MANPATH=$MANPATH:$(pwd -P)/docs/dist/man -Or you can move manpages from docs/dist/man directory to some +Or you can move man pages from docs/dist/man directory to some other directory and add it to MANPATH. Full HTML documentation can be accessed at docs/dist/html/index.html. -You can also build manpages for types in your ~/.cdist directory: +You can also build only man pages or only html documentation, for +only man pages run: + +.. code-block:: sh + + make man + +for only html documentation run: + +.. code-block:: sh + + make html + +You can also build man pages for types in your ~/.cdist directory: .. code-block:: sh make dotman -Built manpages are now in docs/dist/man directory. If you have +Built man pages are now in docs/dist/man directory. If you have some other custom .cdist directory, e.g. /opt/cdist then use: .. code-block:: sh diff --git a/docs/src/man1/cdist.rst b/docs/src/man1/cdist.rst index efc1a201..5b821d46 100644 --- a/docs/src/man1/cdist.rst +++ b/docs/src/man1/cdist.rst @@ -56,10 +56,6 @@ CONFIG ------ Configure one or more hosts -.. option:: -h, --help - - Show the help screen - .. option:: -c CONF_DIR, --conf-dir CONF_DIR Add a configuration directory. Can be specified multiple times.