From: Michael Smith Date: Sun, 26 Mar 2006 01:56:19 +0000 (+0000) Subject: Added support for auto-recognizing DocBook element names in X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=206c7c3d6af4ce1c71e763dba5f3d6639afb8d65;p=docbook-dsssl Added support for auto-recognizing DocBook element names in commit descriptions and marking them up with foo instances. --- diff --git a/releasetools/Targets.mk b/releasetools/Targets.mk index 0c8b4c6c1..d2c9c282a 100644 --- a/releasetools/Targets.mk +++ b/releasetools/Targets.mk @@ -30,6 +30,11 @@ NEWS.xml: ChangeLog.xml $(XSLT) $< $(NEWS_MAKER) $@ \ latest-tag="'$(shell cat LatestTag)'" \ release-version="'$(RELVER)'" + for element in \ + $(shell $(XSLT) $(DOCBOOK_RNG) $(GET_ELEMENT_NAMES) | sort | uniq); \ + do $(SED) $(SED_OPTS) -i \ + "s/\([^<\/A-Za-z0-9_\.\-]\)\($$element\)\([^A-Za-z0-9_\.\-]\)/\1\2<\/FOOM>\3/g" $@; done; \ + $(SED) $(SED_OPTS) -i s/FOOM/tag/g $@ NEWS.html: NEWS.xml $(XSLT) $< $(DOC-LINK-STYLE) $@ diff --git a/releasetools/Variables.mk b/releasetools/Variables.mk index 2ee82a5b9..e134c91e1 100644 --- a/releasetools/Variables.mk +++ b/releasetools/Variables.mk @@ -34,6 +34,10 @@ NEWS_MAKER=docsrc/release-notes.xsl # stylesheet used for determining the latest cvs tag in cvs log GET_LATEST_TAG=docsrc/get-latest-tag.xsl +GET_ELEMENT_NAMES=docsrc/get-element-names.xsl + +DOCBOOK_RNG=../docbook/relaxng/docbook/docbook.rng + # stylesheet for generating FO version of release notes FO-STYLE=$(DOCBOOK_CVS)/xsl/fo/docbook.xsl