blob: 45d7e4a1cdf1b06038bed5d6bcd8ad75700703df (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
|
<?xml version="1.0" encoding="UTF-8"?>
<project name="org.eclipse.linuxtools.lttng.help" default="all">
<description>
Generate Eclipse help content for the Linux Tools LTTng user guide
</description>
<!-- Set correct values -->
<property name="help.doc.url.base" value="http://wiki.eclipse.org" />
<property name="ug.path" value="Linux_Tools_Project/LTTng2/User_Guide" />
<property name="ug.title" value="LTTng Plug-in User Guide" />
<!-- Replace dir with the dir you have eclipse installed into.-->
<property name="eclipse.dir" value="/home/francois/Eclipse/Indigo" />
<property name="temp.dir" value="/home/francois/tmp" />
<path id="wikitext.tasks.classpath">
<fileset dir="${eclipse.dir}/plugins">
<include name="org.eclipse.mylyn.wikitext.*core*.jar" />
</fileset>
</path>
<!-- Uncomment and set proxy host and port if necessary -->
<!--
<setproxy proxyhost="host" proxyport="port"/>
-->
<taskdef classpathref="wikitext.tasks.classpath" resource="org/eclipse/mylyn/internal/wikitext/mediawiki/core/tasks/tasks.properties" />
<taskdef classpathref="wikitext.tasks.classpath" resource="org/eclipse/mylyn/wikitext/core/util/anttask/tasks.properties" />
<target name="all" description="Generate Eclipse help content for the Linux Tools LTTng User Guide">
<sequential>
<wikitext-to-eclipse-help markupLanguage="MediaWiki"
validate="true"
failonvalidationerror="true"
overwrite="true"
multipleOutputFiles="true"
navigationimages="true"
title="${ug.title}"
formatoutput="true"
helpPrefix="doc">
<fileset dir="./doc">
<include name="User-Guide.mediawiki" />
</fileset>
<stylesheet url="book.css" />
</wikitext-to-eclipse-help>
<antcall target="test" />
<mediawiki-to-eclipse-help wikiBaseUrl="${help.doc.url.base}" title="${ug.title}" formatoutput="true" dest="." templateExcludes="*eclipseproject*">
<path name="${ug.path}" title="${ug.title}" generateToc="false" />
<stylesheet url="book.css" />
<pageAppendum>
= Updating This Document =
This document is maintained in a collaborative wiki. If you wish to update or modify this document please visit
http://wiki.eclipse.org/Linux_Tools_Project/LTTng2/User_Guide.
</pageAppendum>
</mediawiki-to-eclipse-help>
</sequential>
</target>
<target name="test" description="Verify that all of the HTML files are well-formed XML">
<echo level="info">
Validating help content XML and HTML files: The Eclipse help system expects well-formed XML
If validation fails it is because either:
* the userguide source code is poorly formed, or
* the WikiText MediaWiki parser has a bug
Problems with userguide source are usually caused by improper use of HTML markup in the MediaWiki source,
or inadvertently starting a line with a space character (in MediaWiki this starts a preformatted block)
</echo>
<!--
Don't bother with DTD validation: we only care if the files are well-formed.
We therefore provide an empty DTD
-->
<echo file="${temp.dir}/__empty.dtd" message="" />
<xmlvalidate lenient="true">
<fileset dir="doc">
<include name="**/*.html" />
</fileset>
<dtd publicid="-//W3C//DTD XHTML 1.0 Transitional//EN" location="${temp.dir}/__empty.dtd" />
</xmlvalidate>
<delete file="${temp.dir}/__empty.dtd" />
</target>
</project>
|