Git Product home page Git Product logo

transpect.github.io's Introduction

transpect.github.io

Author: Martin Kraetke

The HTML pages of transpect.github.io are generated automatically with XSLT/XProc-based scripts from a source DocBook file where the content is stored. The DocBook XML is splitted into chunks and converted into HTML. Each HTML chunk is inserted into an HTML template, which use the Materialize CSS framework, an implementation of Googles Material Design.

prerequisites

  • Java 1.7 or later
  • XML Calabash

edit the content

The content is stored as DocBook XML file in the source directory. You have to follow some markup conventions in DocBook.

  • Each part represents an main nav entry in the left nav bar.
  • Every part must contain at least one chapter element representing a single web page. The chapter element must include an @xml:base attribute indicating the filename of the HTML page.
<part>
  <title>About</title>
  <chapter xml:base="index.html">
    <title>transpect</title>
    <subtitle>A open source framework for converting and checking data</subtitle>
    <!-- (…) --> 
  </chapter>
</part>
  • If a 'part' contains multiple chapter elements, then a dropdown with the corresponding entries is generated. The dropdown title is the part title and the subentries are the chapter titles.
  • section elements below a chapter are automatically connected witht the left mini-toc.

build the website

  • Checkout the repository with Git and change into the directory.
$ git clone https://github.com/transpect/transpect.github.io.git website
$ cd website

Execute the XProc build script with XML Calabash

$ ./calabash/calabash.sh xpl/build.xpl

If you want to request GitHub for updated transpect modules, you have to add the option sync=yes. Unfortunately, GitHub limits API requests to 60 per hour. To bypass this limitation, you can obtain a personal access token from your GitHub personal settings and add the value to the option named token.

$ ./calabash/calabash.sh xpl/build.xpl sync=yes token=123456

Commit HTML and DocBook with Git.

$ git add *.html source/source.dbk
$ git commit -m 'update website'
$ git push

transpect.github.io's People

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

transpect.github.io's Issues

"Getting started" section is incomplete/out-of-date

Following the Getting started tutorial as written does not lead to a working example of transpect.

In addition to the problem with the unzip-extension module, as described in this issue, the tutorial doesn't mention the need to install the htmlreports module. Without it, executing calabash produces the following error message:
$ ./calabash/calabash.sh -o result=MyXMLfile.xml docx2hub/xpl/docx2hub.xpl docx=MyWordfile.docx
ERROR: docx2hub/xpl/docx2hub.xpl:113:74:err:XS0052:Cannot import: http://transpect.io/htmlreports/xpl/errorPI2svrl.xpl
ERROR: cause: I/O error reported by XML parser processing http://transpect.io/htmlreports/xpl/errorPI2svrl.xpl: http://transpect.github.io/htmlreports/xpl/errorPI2svrl.xpl
ERROR: It is a static error if the URI of a p:import cannot be retrieved or if, once retrieved, it does not point to a p:library, p:declare-step, or p:pipeline.
ERROR: Underlying exception: I/O error reported by XML parser processing http://transpect.io/htmlreports/xpl/errorPI2svrl.xpl: http://transpect.github.io/htmlreports/xpl/errorPI2svrl.xpl

Cloning the htmlreports module (and adding it to the xmlcatalog) solves the issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.