Skip to content

Commit

Permalink
Merge pull request #27 from ndw/master
Browse files Browse the repository at this point in the history
Fix profiling and improve the build.
  • Loading branch information
ndw authored Nov 21, 2016
2 parents 2061bf2 + ca81ef3 commit 2dca9c4
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 38 deletions.
8 changes: 2 additions & 6 deletions en/bin/circle-ci-deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,9 @@ if [ "$GITHUB_CNAME" != "" ]; then
echo $GITHUB_CNAME > CNAME
fi;

if [ -d ./tdg/{$DBVERSION} ]; then
git rm -rf ./tdg/${DBVERSION}
fi

mkdir -p ./tdg/${DBVERSION}
cp -Rf $BUILD/html/* ./tdg/${DBVERSION}/
rsync -ar --delete $BUILD/html/ ./tdg/${DBVERSION}/

git add -f .
git add --all .
git commit -m "CircleCI build: $CIRCLE_BUILD_URL"
git push -fq origin gh-pages
9 changes: 6 additions & 3 deletions en/defguide5/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,10 @@ task tdgxml(dependsOn: ['bookmeta', 'patterns', 'refpages'], type: XMLCalabashTa
pipeline "../xpl/xinclude.xpl"
}

task book(dependsOn: 'tdgxml', type: XMLCalabashTask) {
task book(dependsOn: ['tdgxml', 'setupDocBook'], type: XMLCalabashTask) {
inputs.file file("build/tdg.xml")
inputs.file file("../xpl/make-book.xpl")
inputs.file file("../stylesheets/profile.xsl")
inputs.file file("build/docbook/xslt/base/preprocess/30-profile.xsl")
inputs.file file("../stylesheets/purpose.xsl")
inputs.file file("../stylesheets/tdg2db.xsl")
inputs.file file("../stylesheets/profile.xsl")
Expand All @@ -168,7 +168,10 @@ task book(dependsOn: 'tdgxml', type: XMLCalabashTask) {
output("result", "build/book.xml")
option("arch", "assembly defguide5")
option("revision", "5.0 5.1")
option("condition", "refpages web")
// This crazy list of conditions is a side effect of the fact that
// I carelessly decided to override the condition attribute for
// something else inthe reference pages. :-(
option("condition", "expanded ref.desc.attribute-descriptions ref.desc.attributes ref.desc.children ref.desc.parents ref.description ref.desc.rules ref.desc.seealso ref.examples refpages web")
pipeline "../xpl/make-book.xpl"
}

Expand Down
2 changes: 1 addition & 1 deletion en/defguide5/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
docbookXsltBaseUri=http://cdn.docbook.org
docbookXsltVersion=2.0.21
bookVersion=1.4.18
bookVersion=1.4.19
docbookVersion=V5.2b1
rnd=defguide.rnd
2 changes: 1 addition & 1 deletion en/stylesheets/chunk.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
exclude-result-prefixes="ch db f fn h m t xs"
version="2.0">

<xsl:import href="http://docbook.github.com/release/latest/xslt/base/html/chunk.xsl"/>
<xsl:import href="../defguide5/build/docbook/xslt/base/html/chunk.xsl"/>

<xsl:include href="custom.xsl"/>

Expand Down
19 changes: 0 additions & 19 deletions en/stylesheets/tdg.xsl

This file was deleted.

15 changes: 7 additions & 8 deletions en/xpl/make-book.xpl
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
<p:output port="result" />
<p:input port="parameters" kind="parameter"/>

<p:option name="not-condition" select="'compact print'"/>
<p:option name="condition" select="''"/>
<p:option name="not-arch" select="''"/>
<p:option name="arch" select="'defguide5'"/>
<p:option name="revision" required="true"/>

<!--
<p:import href="../defguide5/build/docbook/xslt/base/pipelines/docbook.xpl"/>
-->

<p:variable name="srcbase" select="base-uri(/)"/>

Expand All @@ -21,13 +21,12 @@

<p:xslt name="profiled">
<p:input port="stylesheet">
<p:document href="../stylesheets/profile.xsl"/>
<p:document href="../defguide5/build/docbook/xslt/base/preprocess/30-profile.xsl"/>
</p:input>
<p:with-param name="condition" select="$condition"/>
<p:with-param name="not-condition" select="$not-condition"/>
<p:with-param name="arch" select="$arch"/>
<p:with-param name="not-arch" select="$not-arch"/>
<p:with-param name="revision" select="$revision"/>
<p:with-param name="profile.separator" select="' '"/>
<p:with-param name="profile.condition" select="$condition"/>
<p:with-param name="profile.arch" select="$arch"/>
<p:with-param name="profile.revision" select="$revision"/>
<p:log port="result" href="/tmp/tdg-profile.xml"/>
</p:xslt>

Expand Down

0 comments on commit 2dca9c4

Please sign in to comment.