# Makefile for SDP docs from AsciiDoctor format to HTML and PDF ADOC_SRC = $(wildcard *.adoc) MD_SRC = $(wildcard *.md) $(wildcard ../*.md) PDF = $(ADOC_SRC:.adoc=.pdf) HTML = $(ADOC_SRC:.adoc=.html) $(MD_SRC:.md=.html) SCRIPT_MAN_PAGE_GENERATOR = ../../tools/gen_script_man_pages.sh # Warning: Using a wildcard here eases maintenance, but will # not trigger a make if generated doc files are removed. Handle # such a situation manually. SDP_GUIDE_UNIX_GENDOCS = $(wildcard gen/*.man.txt) SDP_LEGACY_UPGRADES_GENDOCS = gen/clear_depot_Map_fields.sh.man.txt # Default target 'all' builds PDF and HTML from *.adoc files. For # any referenced generated man pages, current files in the 'gen' # directory are used. See 'full'. all: $(PDF) $(HTML) # The 'full' target ensures docs are generated from the latest # files. It does a 'p4 sync' in the SDP workspace to ensure # we have the latest scripts. # # WARNING: The 'full' target does a 'p4 sync' and could potentially # schedule a resolve. If a resolve is needed for scripts from # which docs are generated, generated docs will be incorrect. full: $(PDF) $(HTML) GenerateScriptManPages .PHONY: GenerateScriptManPages GenerateScriptManPages: p4 -s sync $(SCRIPT_MAN_PAGE_GENERATOR) -rec # General Rule for converting Markdown files to HTML. # Note that you can use: pip3 install markdown and then have a script: # python3 -m markdown x.md > x.html %.html: %.md rm -f $@ markdown $^ > $@ # General Rule for converting AsciiDoc files to HTML. %.html: %.adoc rm -f $@ asciidoctor $^ # General Rule for converting AsciiDoc files to PDF. %.pdf: %.adoc rm -f $@ asciidoctor-pdf -a pdf-themesdir=themes -a pdf-theme=basic $^ # Specific Rule for building SDP_Guide.Unix.html with generated docs. SDP_Guide.Unix.html: SDP_Guide.Unix.adoc $(SDP_GUIDE_UNIX_GENDOCS) rm -f SDP_Guide.Unix.html asciidoctor SDP_Guide.Unix.adoc # Specific Rule for building SDP_Guide.Unix.pdf with generated docs. SDP_Guide.Unix.pdf: SDP_Guide.Unix.adoc $(SDP_GUIDE_UNIX_GENDOCS) rm -f SDP_Guide.Unix.pdf asciidoctor-pdf -a pdf-themesdir=themes -a pdf-theme=basic SDP_Guide.Unix.adoc # Specific Rule for building SDP_Legacy_Upgrades.Unix.html with generated docs: SDP_Legacy_Upgrades.Unix.html: SDP_Legacy_Upgrades.Unix.adoc $(SDP_LEGACY_UPGRADES_GENDOCS) rm -f SDP_Legacy_Upgrades.Unix.html asciidoctor SDP_Legacy_Upgrades.Unix.adoc # Specific Rule for building SDP_Legacy_Upgrades.Unix.pdf with generated docs. SDP_Legacy_Upgrades.Unix.pdf: SDP_Legacy_Upgrades.Unix.adoc $(SDP_LEGACY_UPGRADES_GENDOCS) rm -f SDP_Legacy_Upgrades.Unix.pdf asciidoctor-pdf -a pdf-themesdir=themes -a pdf-theme=basic SDP_Legacy_Upgrades.Unix.adoc .PHONY: clean rec clean: rm -f $(PDF) $(HTML) rec: p4 rec
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#13 | 30439 | Robert Cowham | Update to README and Makefile comment for rebuild | ||
#12 | 30000 | C. Thomas Tyler |
Refined Release Notes and top-level README.md file in preparation for coming 2023.2 release. Adjusted Makefile in doc directory to also generate top-level README.html from top-level README.md file so that the HTML file is reliably updated in the SDP release process. Updated :revnumber: and :revdate: docs in AsciiDoc files to indicate that the are still current. Avoiding regen of ReleaseNotes.pdf binary file since that will need at least one more update before shipping SDP 2023.2. |
||
#11 | 29833 | C. Thomas Tyler | Added rule for generating HTML from Markdown using 'markdown' binary. | ||
#10 | 29696 | C. Thomas Tyler | Makefile tweak. | ||
#9 | 27722 | C. Thomas Tyler |
Refinements to @27712: * Resolved one out-of-date file (verify_sdp.sh). * Added missing adoc file for which HTML file had a change (WorkflowEnforcementTriggers.adoc). * Updated revdate/revnumber in *.adoc files. * Additional content updates in Server/Unix/p4/common/etc/cron.d/ReadMe.md. * Bumped version numbers on scripts with Version= def'n. * Generated HTML, PDF, and doc/gen files: - Most HTML and all PDF are generated using Makefiles that call an AsciiDoc utility. - HTML for Perl scripts is generated with pod2html. - doc/gen/*.man.txt files are generated with .../tools/gen_script_man_pages.sh. #review-27712 |
||
#8 | 27536 | C. Thomas Tyler |
Legacy Upgrade Guide doc updates: * Added 'Put New SDP in Place' section. * Added 'Set SDP Counters' section to set SDP_VERSION and SDP_DATE counters. * Covered updating depot spec Map fields. * Covered adding server.id files. * Added missing content on putting new SDP directory in place. SDP_Guide.Unix doc updates: * Added Legacy Upgrade Scripts section w/clear_depot_Map_fields.sh. Updated Makefile with new doc build dependencies. Regenerated docs. |
||
#7 | 27398 | C. Thomas Tyler | Refined Makefile for generating docs and regenerated docs. | ||
#6 | 27397 | C. Thomas Tyler |
Minor tweaks to doc Makefile; added 'rec' target. Changed toc notes to 2 levels for Release Notes. |
||
#5 | 27049 | C. Thomas Tyler |
Enhanced doc generation Makefile: * Added new 'full' target to 'p4 sync' and generate script man pages. * Added new 'GenerateAllScriptManPages' target. * Added dependency on generated script man pages. |
||
#4 | 27041 | Robert Cowham |
Windows Guide directly includes chunks of the Unix guide for replication etc, with a little ifdef to avoid Unix only comments. Fix Makefile and add missing generated man page. |
||
#3 | 26783 | C. Thomas Tyler |
Enhanced Makefile for AsciiDocc to support building individual targets, and also incrementally build only what's needed. |
||
#2 | 26629 | Robert Cowham |
Fixed Makefile to generate HTML Check in theme Some notes in README Remove the .docx! |
||
#1 | 26628 | Robert Cowham | Basically have things working for AsciiDoc |