增加 maven 仓库。

+YUCHENG HU+

git-svn-id: https://svn.code.sf.net/p/hawebs/svn@385 a2543c7e-f6e9-4f8a-8bff-1ffc34733512
This commit is contained in:
YuCheng Hu
2010-06-28 05:50:40 +00:00
parent a725f9e8e1
commit d03e9e4214
20 changed files with 1382 additions and 0 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 742 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 335 B

+110
View File
@@ -0,0 +1,110 @@
/**
* Copyright (C) 2006-2010 YUCHENG HU
*
* ---------------------------------------------
* HA WEBSYSTEMS
* http://www.hawebs.net
* https://www.hawebs.org/forums/computer/
*
* CONTACT
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* ---------------------------------------------
* [A] GNU GENERAL PUBLIC LICENSE GNU/LGPL
* [B] Apache License, Version 2.0
*
* ---------------------------------------------
* NOTE
*
* ---------------------------------------------
*/
* {
padding-top: 0px;
padding-right: 0;
padding-bottom: 0;
padding-left: 0;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 0px;
top: auto;
border: none;
}
.topictitle1 {
font-size: 2.5em;
background: url(img03.jpg) repeat-x left bottom;
}
.topictitle2 {
font-size: 2em;
}
body {
margin: 20px 0;
background: #FFFFFF urlrepeat-x left top;
text-align: left;
font-family: Geneva, Arial, Helvetica, sans-serif;
font-size: 0.9em;
color: #333333;
float: left;
padding-top: 0;
padding-right: 5px;
padding-bottom: 0;
padding-left: 30px;
}
h1, h2, h3 {
padding-bottom: 10px;
margin-bottom: 15px;
text-transform: uppercase;
font-family: Arial, Helvetica, sans-serif;
}
p, ul, ol, dl {
margin-top: 0.2em;
margin-bottom: 0.8em;
}
ul, ol, dl {
margin-left: 1.2em;
}
dt {
font-weight: bold;
}
dd {
margin-left: 3em;
}
blockquote {
margin-left: 3em;
margin-right: 3em;
font-style: italic;
}
a {
border: none;
text-decoration: underline;
color: #004080;
line-height: 1.4em;
}
a:hover {
border: none;
color: #FF3333;
text-decoration:none;
}
/* Header */
#header {
width: 960px;
height: 90px;
margin: 20;
float: left;
}
pre {
font-family: "Courier New", Courier, monospace;
}
.codeph{
font-family: "Courier New", Courier, monospace;
}
@@ -0,0 +1,83 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!-- (c) Copyright HAWEBS. 2006, 2010 All Rights Reserved. -->
<!--
| HA WEBSYSTEMS
| http://www.hawebs.net
| http://www.tcivis.com
|
| Contact
| huyuchengus@gmail.com / yuchenghu@hawebs.net
| +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
| GNU GENERAL PUBLIC LICENSE / Apache License, Version 2.0
|
| basedir can be specified to other places base on your need.
|
| Note: input, output, and temp directories will base on the basedir if
| they are relative paths.
* -->
<project name="DITA_OT_xhtml_gettingstarted" default="DITA_OT_xhtml_gettingstarted" basedir="../..">
<property file="${basedir}/docs.properties"/>
<!-- dita.dir should point to the toolkit's root directory -->
<property name="book.name" value="definitive_guide"/>
<property name="xhtml.path" value="docs"/>
<property name="dita.input.dir" value=""/>
<property name="book.output.dir" value="${dita.output.dir}/${book.name}/${xhtml.path}"/>
<property name="images.source.dir" value="${basedir}${file.separator}src${file.separator}images"/>
<property name="css.source.dir" value="${basedir}${file.separator}src${file.separator}css"/>
<import file="${dita.dir}${file.separator}integrator.xml"/>
<target name="DITA_OT_xhtml_gettingstarted" depends="integrate">
<echo>This file uses a simple CSS file to create a new, more colorful look and feel for generatedXHTML files.</echo>
<ant antfile="${dita.dir}${file.separator}build.xml" target="init">
<property name="args.input" value="src/${book.name}/${book.name}.ditamap"/>
<property name="output.dir" value="${book.output.dir}"/>
<property name="transtype" value="xhtml"/>
<property name="dita.extname" value=".dita"/>
<property name="args.xhtml.toc" value="toc"/>
<!-- args.css = the name of the CSS file -->
<property name="args.css" value="public.css"/>
<!-- args.csspath = the path relative to the output directory; in this case, the CSS will be in out/css -->
<property name="args.csspath" value="css"/>
<!-- args.copycss = whether to copy the CSS file to the output directory. -->
<property name="args.copycss" value="yes"/>
<!-- args.cssroot = where to find the CSS file on the local file system. -->
<property name="args.cssroot" value="${css.source.dir}"/>
</ant>
<!-- The toolkit currently does not scan CSS files to retrieve
related resources. The sample CSS above references two JPG files;
copy those files to the output CSS directory (output.dir + csspath). -->
<copy todir="${book.output.dir}${file.separator}css">
<fileset dir="${css.source.dir}"
includes="*.jpg"/>
</copy>
<copy todir="${book.output.dir}${file.separator}images">
<fileset dir="${images.source.dir}" >
<include name="**/*.jpg"/>
<include name="**/*.jpeg"/>
<include name="**/*.png"/>
<include name="**/*.gif"/>
</fileset>
</copy>
<copy todir="${book.output.dir}">
<fileset dir="${dita.dir}/resource" includes="*.html"/>
</copy>
</target>
</project>
@@ -0,0 +1,65 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<map title="Maven权威指南" id="definitive-guide">
<topicmeta>
<copyright>
<copyryear year="2006, 2010"/>
<copyrholder>HAWEBS信息技术股份有限公司</copyrholder>
</copyright>
<prodinfo>
<prodname>Maven权威指南</prodname>
<vrmlist>
<vrm version="1.0.0.0"/>
</vrmlist>
<brand>HAWEBS Maven</brand>
</prodinfo>
</topicmeta>
<reltable>
<relrow>
<relcell/>
<relcell/>
</relrow>
<relrow>
<relcell>
<topicref navtitle="NULL" href="tasks/info/hacopyright.dita"/>
</relcell>
<relcell/>
</relrow>
</reltable>
<topicref navtitle="" href="tasks/info/hacopyright.dita"/>
<topicref href="tasks/info/apachelicense.dita"/>
<topicref href="tasks/chapter1/chapter1.dita">
<topicref href="tasks/chapter1/chapter1_1.dita"/>
</topicref>
</map>
@@ -0,0 +1,91 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This file is part of the DITA Open Toolkit project hosted on
Sourceforge.net. See the accompanying license.txt file for
applicable licenses.-->
<!-- (c) Copyright IBM Corp. 2005, 2006 All Rights Reserved. -->
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
<task id="addmeta" xml:lang="en-us">
<title>Adding metadata to elements</title>
<shortdesc>You can use attributes to provide information about what
product, audience, or platform an element applies to, or what revision
it belongs to.</shortdesc>
<prolog>
<metadata>
<keywords>
<indexterm>metadata
attributes<indexterm>adding</indexterm></indexterm>
<indexterm>adding metadata attributes</indexterm>
</keywords>
</metadata>
</prolog>
<taskbody>
<prereq>Before using these attributes, work with your team to agree on
a consistent set of values for use across your information set. Do
not define your own values without consulting team mates, or your
content might not build properly when reusing it.</prereq>
<context>Use these attributes when you have content within a topic or a
map that applies to only one or some of the products, platforms, or
audiences for the topic or map as a whole.</context>
<steps>
<step>
<cmd>Find the element you want to provide information for.</cmd>
<info>If there are not attributes you need in the element,
create a new element inside it, like a ph, which can hold
the attributes instead. </info>
</step>
<step>
<cmd>Enter the value of attribute for the information you want
to provide:</cmd>
<?Pub Caret?>
<choicetable>
<chrow>
<choption>audience</choption>
<chdesc>The audience that the element applies to, Could
be a user role (like administrator), experience
level (novice), or combination
(novice-admin).</chdesc>
</chrow>
<chrow>
<choption>platform</choption>
<chdesc>The platform (typically hardware, operating
system, or both) that the element applies
to.</chdesc>
</chrow>
<chrow>
<choption>product</choption>
<chdesc>The product that the element applies
to.</chdesc>
</chrow>
<chrow>
<choption>otherprops</choption>
<chdesc>Any other category of metadata.</chdesc>
</chrow>
<chrow>
<choption>rev</choption>
<chdesc>The revision that the element belongs to, if
the topic has been revised and you want to track
what stage particular content was added at.</chdesc>
</chrow>
</choicetable>
</step>
<step>
<cmd>Add a value or values to the attribute.</cmd>
<stepxmp>For example, audience="novice-admin expert-user" or
platform="wintel".</stepxmp>
</step>
<step importance="optional">
<cmd>For <i>audience</i> or <i>product</i>, add an equivalent
element to the prolog metadata.</cmd>
<info>You can provide more information about your audience or
product values in the topic's prolog, inside the metadata
element. To ensure consistency, you can define the elements
in one place for the entire information set, and then reuse
them in topics that require them by using the <i>conref</i>
attribute.</info>
</step>
</steps>
<result>Metadata attributes are inherited: they apply to any elements
they contain as well. In a table, metadata for a column applies to
all the cells in the column.</result>
</taskbody>
</task>
@@ -0,0 +1,48 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="chapter1" xml:lang="zh">
<title>介绍 Apache Maven</title>
<shortdesc>主要对 Apache Maven 进行了简要的描述。</shortdesc>
<prolog>
<metadata>
<keywords>
<indexterm>Apache</indexterm>
<indexterm>Maven</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody/>
</concept>
@@ -0,0 +1,51 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="test_drive" xml:lang="zh">
<title>Maven 它是什么</title>
<prolog>
<metadata>
<keywords>
<indexterm>Apache</indexterm>
<indexterm>Maven</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody>
<p>如何回答这个问题要看你怎么看这个问题。绝大部分Maven用户都称Maven是一个&quot;构建工具&quot;:一个用来把源代码构建成可发布的构件的工具。构建工程师和项目经理会说Maven是一个更复杂的东西:一个项目管理工具。那么区别是什么?像Ant这样的构建工具仅仅是关注预处理,编译,打包,测试和分发。像Maven这样的一个项目管理工具提供了构建工具所提供功能的超集。除了提供构建的功能,Maven还可以生成报告,生成Web站点,并且帮助推动工作团队成员间的交流。</p>
<p>一个更正式的 <xref format="html" scope="external" href="http://maven.apache.org/">Apache Maven</xref> 的定义: Maven是一个项目管理工具,它包含了一个项目对象模型 (Project Object Model),一组标准集合,一个项目生命周期(Project Lifecycle),一个依赖管理系统(Dependency Management System),和用来运行定义在生命周期阶段(phase)中插件(plugin)目标(goal)的逻辑。 当你使用Maven的时候,你用一个明确定义的项目对象模型来描述你的项目,然后 Maven 可以应用横切的逻辑,这些逻辑来自一组共享的(或者自定义的)插件。</p>
<p>别让Maven是一个&quot;项目管理&quot;工具的事实吓跑你。如果你只是在找一个构建工具,Maven能做这个工作。 事实上,本书的一些章节将会涉及使用Maven来构建和分发你的项目。 </p>
</conbody>
</concept>
@@ -0,0 +1,50 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="hudson_best_practices" xml:lang="zh">
<title>Hudson 最佳实践</title>
<shortdesc/>
<prolog>
<metadata>
<keywords>
<indexterm>Hudson</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody>
<p>持续集成并整合自动测试,在近几年已经得到了广泛的使用。在持续集成的背后隐藏着软件公司对构建管理、发行管理、自动部署和测试流程方式的转变。</p>
<p>这部分提供了针对 Hudson 的一系列最佳实践。Hudson 作为一套持续集成的解决方案,能够为公司管理者、商业运行管理者、软件开发人员、架构师在软件开发过程中,提供最为有效管理。同时,也能为软件开发的生命周期中提供从开发进程到代码质量管理的有效控制。</p>
</conbody>
</concept>
@@ -0,0 +1,61 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="hudson_features" xml:lang="zh">
<title>Hudson 的特性</title>
<shortdesc/>
<prolog>
<metadata>
<keywords>
<indexterm>Hudson</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody>
<p>Hudson 包含有下面的一些特性:</p>
<ol>
<li>易于安装<p>只需要运行<codeph> java -jar hudson.war</codeph> 就能够完成安装,或者你也可以将 Hudson 部署到 Sevlet 容器中。Hudson除此之外不需要其他任何安装,也不需要数据库支持。</p></li>
<li>易于配置<p>Hudson 可以使用 GUI 界面对软件进行配置。在配置过程中能够对配置进行智能检查,同时也提供了丰富的帮助信息。Hudson 不再需要你去读取难懂的 XML 配置文件。当然,如果你愿意,你也可以通过修改 XML 配置文件完成配置。</p></li>
<li>变更集支持<p>Hudson 可以从 CVS/Subversion 中生成一系列的变更集。能够更好的提高交互性,同时能有效果降低版本控制服务器的负载。</p></li>
<li>URL 静态化<p>Hudson 能够在几乎所有的页面中提供易读的 URL 链接。其中包括一些永久链接,例如:【最后一次的构建】 / 【最后成功一次的构建】。这些链接能够更加容易的被链接到其他地方。</p></li>
<li>聚合新闻 (RSS) / 电子邮件 (Email) / 实时聊天工具 (IM)的支持<p>可以通过聚合新闻或者电子邮件来对构建失败的结果获得实时通知。</p></li>
<li>事后标注<p>构建可以在构建完成后进行标注</p></li>
<li>JUnit/TestNG 测试报告<p>JUnit 的测试报告可以用报表,概要,历史信息的方式进行报告,例如,当进入测试断点。也可以将历史趋势用图图表进行表示。</p></li>
<li>分布式构建<p>Hudson 可以在多台计算机上进行分布式 构建/测试。这样可以让你获更多供发人员使用的,但是空闲的工作站。</p></li>
<li>文件指纹<p>Hudson 可以持续跟踪创建的 Jar 文件,同时跟踪使用 Jar 文件的版本。这样甚至能够让你跟踪在 Hudson 之外的 Jar 文件。同时,能为不同的项目独立的跟踪 Jar 文件。</p></li>
<li>插件支持<p>Hudson 可以通过第三方插件支持扩展。你甚至可以为你的项目小组单独为 Hudson 扩展工具或过程。</p></li>
</ol>
</conbody>
</concept>
@@ -0,0 +1,80 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="hudson_origin" xml:lang="zh">
<title>Hudson 的由来与目标</title>
<prolog>
<metadata>
<keywords>
<indexterm>Hudson</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody>
<p>持续集成(CI)已成为当前许多软件开发团队在整个软件开发生命周期内侧重于保证代码质量的常见做法。它是一种实践,旨在缓和和稳固软件的构建过程。并且能够帮助您的开发团队应对如下挑战:<ul>
<li>软件构建自动化 <p>使用CI,您只要按一下按钮,它会依照预先制定的时间表,或者针对某一特定事件,就开始对目标软件进行一次构建过程。想想吧,尤其您从头到尾构建一个构 件的时候,这个构建过程应该不会是局限于某一特定IDE、电脑或者个人的。</p></li>
<li>构建可持续的自动化检查<p>CI系统能够设定成持续地执行新增或修改后签入的源代码,也就是说,当软件开发团队需要周期性的检查新增或修改后的代码时,CI系统会不断确认这些新代 码是否破坏了原有软件的成功构建。这减少了开发者们在检查彼此相互依存的代码中变化情况需要花费的时间和精力。</p></li>
<li>构建可持续的自动化测试<p>一个构建检查的扩展部分,这个过程确保当新增或修改代码时不会导致预先制定的一套测试在构建构件后失败。构建检查和测试一样,失败都会触发通知单 (Email,RSS等等)给相关的当事人,告知对方一次构建或者一些测试失败了。</p></li>
<li>生成后后续过程的自动化<p>一旦自动化检查和测试的构建已经完成,一个软件构件的构建周期中可能也需要一些额外的任务,诸如生成文档、打包软件、部署构件到一个运行环境或者软件仓 库。这样,构件才能更迅速地提供给用户使用。</p></li>
</ul></p>
<p> 实现一个CI服务器你需要的最低要求是,一个比较容易获取的源代码仓库(包含源代码),一套构建脚本和程序,一系列围绕构件构建的可执行测试。</p>
<p>下图概括了CI系统的基本结构:<image href="../../images/introduction_ci.jpg">
<alt>CI 流程图</alt>
</image></p>
<p>该系统的各个组成部分是按如下顺序来发挥作用的<ol>
<li>开发者检查新增和修改到源代码仓库后的代码。</li>
<li>CI服务器会为每一个项目创建了一个单独的工作区。当预设或请求一次新的构建时,它将把源代码仓库的源码存放到对应的工作区,哪里构建就执行哪里。 </li>
<li>CI服务器会在新近创建或者更新的工作区内执行构建过程。</li>
<li>一旦构建完成,CI服务器就会在一个新的构件中选择性地执行原先定义的一套测试。如果构建失败,相关责任人将会通过电子邮件、即时短信或者其他的 方式获取到(失败)通知。</li>
<li>如果构建成功,这个构件会被打包并转移到一个部署目标(如应用服务器) 和/或存储为软件仓库中的一个新版本。这个如软件仓库可以是CI服务器的一部分,也可以是一个外部的仓库,诸如一个文件服务器或者像Java.net、SourceForge分发的一个有效网址。源代码仓库和构件仓库是可以分开的,实际上它可以利用一些根本没有包含任何源代码控制系统(CVS、SVN、 CSS等等)的CI服务器。</li>
<li>CI服务器通常会用某种控制台来进行项目的配置和调试,并且根据请求发起相应的操作,诸如即时构建、生成报告,或者检索一些构建好的构件。</li>
</ol></p>
<p>而 Hudson 就是这么一个CI服务器。它最初是由Kohsuke Kawaguchi编写的,他是一名Sun工程师,在2005年2月宣布释放了他的博客。现在已经有大约154个版本。 </p>
<p>以下的一些是使用hudson的理由:<ul>
<li>它是所有CI产品在安装和配置上中最简单的。</li>
<li>基于Web的用户界面非常友好、直观和灵活,在许多情况下,还对需单独配置的部分提供了基于AJAX的即时反馈。</li>
<li>Hudson是基于java开发的(如果你是一个Java开发人员,这是非常有用的),但它不仅限于构建基于Java的软件。 </li>
<li>Hudson本身是一个很简洁的组件,但它提供了一组很明确和可扩展API的Hudson组件。这批组成一个大的类库的Hudson组件反过来又丰富了Hudson的功能;它们都是开源的,而且它们可以直接通过Hudson的控制台来进行安装。</li>
</ul></p>
<p>Hudsonn的主要目标是监控软件开发流程,快速显示问题,让开发人员马上解决问题。所以能保证开发人员以及相关人员省时省力提高开发效率。</p>
<p>CI 服务器在整个开发过程中的主要作用是控制:当服务器在代码存储库中探测到修改时,它将运行构建的任务委托给构建过程本身。如果构建失败了,那么 CI 务器将通知相关方面,然后继续监视存储库。它的角色看起来是被动的;但是,它是快速反映问题的关键。</p>
<p>特别它在和maven2的整合上具有以下优点:<ul>
<li>Hudson一切配置都可以在友好的界面上完成,包括其自身的配置和项目特有的配置,值得注意的是有些配置如MAVEN_HOME和Email Server,只需要配置一次,所有的项目就都能用了。XML?不再需要了,不过如果坚持,也可以通过XML配置。 </li>
<li>支持Maven的模块(Module)Hudson对Maven2做了优化,因此它能自动识别Module,每个Module本身也是一个 build job。相当灵活。 </li>
<li>测试报告聚合,所有模块的测试报告都被聚合在一起了,结果一目了然,使用诸如CruiseControl其他CI,这几乎是件不可能完成的任务。 </li>
<li>构件指纹(artifact fingerprint),每次build的结果构件都被很好的自动管理,无需任何配置就可以方便的浏览下载。</li>
</ul></p>
</conbody>
</concept>
@@ -0,0 +1,53 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="test_drive" xml:lang="zh">
<title>Hudson 测试驱动</title>
<shortdesc/>
<prolog>
<metadata>
<keywords>
<indexterm>Hudson</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody>
<p><xref href="https://hudson.dev.java.net/hudson.jnlp" format="jnlp" scope="external">
<image href="../../images/introduction_webstart.gif"/>
</xref>通过 Java Web Start 来为 Hudson 作为测试驱动来运行。成功运行后,通过地址 <xref format="html" href="http://localhost:8080/" scope="external">http://localhost:8080/</xref> 进入控制台界面。</p>
<p>任何你为 Hudson 做的修改将会被保存到 ~/.hudson 目录中。</p>
<p>你修改的数据将会保留在本地,而不会随 Hudson 的重启而丢失。</p>
</conbody>
</concept>
@@ -0,0 +1,53 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<concept id="what_hudson" xml:lang="zh">
<title>什么是 Hudson</title>
<shortdesc/>
<prolog>
<metadata>
<keywords>
<indexterm>Hudson</indexterm>
<indexterm>介绍</indexterm>
</keywords>
</metadata>
</prolog>
<conbody>
<p>Hudson 用来监视可重复执行的工作。例如,用来构建一个软工程或者后台守护进程自动执行任务。Hudson 可以完成很多工作,Hudson 当前主要集中在下面两个功能中:</p>
<ol>
<li>程序的构建和测试软件项目,就好象导航控制和损毁控制。简单来说,Hudson 为项目提供了一个易用的持续集成(CI)的方法,并能够让用户更加容易的获得最新构建产品。同时能够持续和以增量的方式来构建软件产品。</li>
<li>监控一些定期执行的任务。比如,后台守护进程,工作进程邮件,甚至在这些工作运行在远程服务器的时候也能完成这些监控。例如,通过守护进程,你可以收取到一些常规邮件,在进行编译和处理的时候,在出现故障的时候,你也会收到一些这样的邮件。Hudson 保留了所有这样输出,同时能够使你更加容易的获得各种异常或故障信息。 </li>
</ol>
</conbody>
</concept>
@@ -0,0 +1,79 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This file is part of the DITA Open Toolkit project hosted on
Sourceforge.net. See the accompanying license.txt file for
applicable licenses.-->
<!-- (c) Copyright IBM Corp. 2005, 2006 All Rights Reserved. -->
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
<task id="filtcontent" xml:lang="zh">
<title>过滤内容</title>
<shortdesc>
你可以通过 metadata 中的信息来确定忽略的内容。
在默认的情况下,包含所有的内容。
</shortdesc>
<prolog>
<metadata>
<keywords>
<indexterm>metadata attributes<indexterm>filtering
on</indexterm></indexterm>
<indexterm>filtering content</indexterm>
</keywords>
</metadata>
</prolog>
<taskbody>
<context>
在所有的便利里面,必须设定至少一个忽略的参数来将其过滤出来。
</context>
<steps>
<step>
<cmd>Create a DITA filter file in the directory you want to add
the file to. Give the file a descriptive name, such as
"audience-flag-build.ditaval".</cmd>
</step>
<step>
<cmd>Open the file, and type below content into it:</cmd>
<tutorialinfo>
<codeblock>&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;val> &lt;/val></codeblock>
</tutorialinfo>
</step>
<step>
<cmd>Define the property you want to exclude:</cmd>
<substeps>
<substep>
<cmd>Find the attribute name. Type a new property for
exclude by adding a new line <codeph>&lt;prop att="" val="" action="exclude"/></codeph>.</cmd>
</substep>
<substep>
<cmd>Select the attribute ("audience", "platform",
"product", "otherprops") you want to exclude based
on. </cmd>
<stepxmp>For example, "audience".</stepxmp>
</substep>
<substep>
<cmd>Type the value you want to exclude. </cmd>
<stepxmp>For example, "programmer".</stepxmp>
</substep>
</substeps>
<info>You can define more properties by following the steps
above. The final ditaval file with the example values should be like
this:</info>
<tutorialinfo>
<codeblock>&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;val>
&lt;prop att="audience" val="programmer" action="exclude"/>
&lt;/val></codeblock>
</tutorialinfo>
</step>
<step>
<cmd>When you publish output from the topic or map, specify the
filter file you want by using the parameter
<codeph>/filter:{args.input.valfile}</codeph> for the output options.</cmd>
</step>
</steps>
<result>Content is excluded only when all the values in a single
attribute are set to exclude. For example, if you have a list item
that applies to programmer and administrator audiences, and you
exclude programmers, the list item will remain in the output
because it still applies to administrators.</result>
@@ -0,0 +1,114 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This file is part of the DITA Open Toolkit project hosted on
Sourceforge.net. See the accompanying license.txt file for
applicable licenses.-->
<!-- (c) Copyright IBM Corp. 2005, 2006 All Rights Reserved. -->
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
<task id="flagcontent" xml:lang="en-us">
<title>标记内容</title>
<shortdesc>You can set to flag content based on metadata. By default, no
content is flagged.</shortdesc>
<prolog>
<metadata>
<keywords>
<indexterm>metadata attributes<indexterm>flagging
on</indexterm></indexterm>
<indexterm>flagging content</indexterm>
</keywords>
</metadata>
</prolog>
<taskbody>
<prereq>Define a common set of images, and common alternative text for
them, so that you can flag consistent content across your
information set. Generally flagging is supported for block-level
elements such as paragraphs, but not for phrase-level elements
within a paragraph. This ensures that the images flagging the
content are easily scanned by the reader, instead of being buried
in text.</prereq>
<context>
<p>At least one value in at least one attribute must be set to flag
for the element to be flagged.</p>
</context>
<steps>
<step>
<cmd>Create a DITA filter file in the directory you want to add
the file to. Give the file a descriptive name, such as
"audience-flag-build.ditaval".</cmd>
</step>
<step>
<cmd> Open the file, and type below content into it:</cmd>
<tutorialinfo>
<codeblock>&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;val> &lt;/val></codeblock>
</tutorialinfo>
</step>
<step>
<cmd>Define the property you want to flag:</cmd>
<substeps>
<substep>
<cmd>Type a new property for flag by adding a new line
<userinput>&lt;prop att="" val="" action="flag" img="" alt=""/></userinput>.</cmd>
</substep>
<substep>
<cmd>Select the attribute ("audience", "platform",
"product", "otherprops") you want to flag based on.
</cmd>
<stepxmp>For example, "audience".</stepxmp>
</substep>
<substep>
<cmd>Type the value you want to flag. </cmd>
<stepxmp>For example, "programmer".</stepxmp>
</substep>
<substep>
<cmd>Enter the image you want to use to flag the
content. Local absolute paths, or relative
paths from the filter file both are supported. </cmd>
<stepxmp>For example, "D:\resource\delta.gif".</stepxmp>
</substep>
<substep>
<cmd>Type the alternate text for the image that will be
used by screen readers. </cmd>
<stepxmp>For example, "sample alt text".</stepxmp>
</substep>
</substeps>
<info>You can define more properties by following the steps
above. The final ditaval file with the example values should be like
this:<codeblock>&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;val>
&lt;prop att="audience" val="programmer" action="flag" img="D:\resource\delta.gif" alt="sample alt text"/>
&lt;/val></codeblock></info>
</step>
<step>
<cmd>When you publish output from the topic or map, specify the
filter file you want by using the parameter
<codeph>/filter:{args.input.valfile}</codeph> for the output options.</cmd>
</step>
</steps>
<result>Content is flagged when any of the flagged values appears in
any of the attributes. When flagged values are found in a map,
links that are generated from affected topicrefs will be flagged on
output.</result>
<example>
<title>Examples</title>
<dl>
<dlentry>
<dt>&lt;p audience="admin programmer"></dt>
<dd>
<p>When admin is set to flag, the paragraph will be
preceded by the image you specified for admin.</p>
<p>When both values are set to flag, both images will
appear before the paragraph.</p>
</dd>
</dlentry>
<dlentry>
<dt>&lt;topicref platform="linux" href="abc.dita"></dt>
<dd>When linux is set to flag, any links to abc.dita
derived from this topic reference will be flagged with
the image you specified. In addition, any links derived
from child topicrefs will also be flagged: metadata
attributes are inherited.</dd>
</dlentry>
</dl>
</example>
</taskbody>
</task>
@@ -0,0 +1,266 @@
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "../dtd/reference.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<reference id="apachelicense" xml:lang="zh">
<title>Apache 许可证</title>
<shortdesc/>
<prolog>
<metadata>
<keywords>
<indexterm>Apache<indexterm>license</indexterm></indexterm>
</keywords>
</metadata>
</prolog>
<refbody>
<section>
<title>Apache许可证,版本2.0</title>
<codeblock>
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
&quot;License&quot; shall mean the terms and conditions for use,
reproduction, and distribution as defined by Sections 1 through
9 of this document.
&quot;Licensor&quot; shall mean the copyright owner or entity authorized
by the copyright owner that is granting the License.
&quot;Legal Entity&quot; shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under
common control with that entity. For the purposes of this
definition, &quot;control&quot; means (i) the power, direct or indirect,
to cause the direction or management of such entity, whether by
contract or otherwise, or (ii) ownership of fifty percent (50%)
or more of the outstanding shares, or (iii) beneficial ownership
of such entity.
&quot;You&quot; (or &quot;Your&quot;) shall mean an individual or Legal Entity
exercising permissions granted by this License.
&quot;Source&quot; form shall mean the preferred form for making
modifications, including but not limited to software source code,
documentation source, and configuration files.
&quot;Object&quot; form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
&quot;Work&quot; shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
&quot;Derivative Works&quot; shall mean any work, whether in Source or
Object form, that is based on (or derived from) the Work and
for which the editorial revisions, annotations, elaborations,
or other modifications represent, as a whole, an original work
of authorship. For the purposes of this License, Derivative
Works shall not include works that remain separable from, or
merely link (or bind by name) to the interfaces of, the Work
and Derivative Works thereof.
&quot;Contribution&quot; shall mean any work of authorship, including
the original version of the Work and any modifications or
additions to that Work or Derivative Works thereof, that is
intentionally submitted to Licensor for inclusion in the Work
by the copyright owner or by an individual or Legal Entity
authorized to submit on behalf of the copyright owner. For the
purposes of this definition,
&quot;submitted&quot; means any form of electronic, verbal, or written
communication sent to the Licensor or its representatives,
including but not limited to communication on electronic mailing
lists, source code control systems, and issue tracking systems
that are managed by, or on behalf of, the Licensor for the
purpose of discussing and improving the Work, but excluding
communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as &quot;Not a
Contribution.&quot;
&quot;Contributor&quot; shall mean Licensor and any individual or Legal
Entity on behalf of whom a Contribution has been received by
Licensor and subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions
of this License, each Contributor hereby grants to You a
perpetual, worldwide, non-exclusive, no-charge, royalty-free,
irrevocable copyright license to reproduce, prepare Derivative
Works of, publicly display, publicly perform, sublicense, and
distribute the Work and such Derivative Works in Source or
Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have
made, use, offer to sell, sell, import, and otherwise transfer
the Work, where such license applies only to those patent claims
licensable by such Contributor that are necessarily infringed by
their Contribution(s) alone or by combination of their
Contribution(s) with the Work to which such Contribution(s) was
submitted. If You institute patent litigation against any entity
(including a cross-claim or counterclaim in a lawsuit) alleging
that the Work or a Contribution incorporated within the Work
constitutes direct or contributory patent infringement, then any
patent licenses granted to You under this License for that Work
shall terminate as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a &quot;NOTICE&quot; text file as part of its
distribution, then any Derivative Works that You distribute
must include a readable copy of the attribution notices
contained within such NOTICE file, excluding those notices
that do not pertain to any part of the Derivative Works, in
at least one of the following places: within a NOTICE text
file distributed as part of the Derivative Works; within the
Source form or documentation, if provided along with the
Derivative Works; or, within a display generated by the
Derivative Works, if and wherever such third-party notices
normally appear. The contents of the NOTICE file are for
informational purposes only and do not modify the License.
You may add Your own attribution notices within Derivative
Works that You distribute, alongside or as an addendum to
the NOTICE text from the Work, provided that such additional
attribution notices cannot be construed as modifying the
License.
You may add Your own copyright statement to Your modifications
and may provide additional or different license terms and
conditions for use, reproduction, or distribution of Your
modifications, or for any such Derivative Works as a whole,
provided Your use, reproduction, and distribution of the Work
otherwise complies with the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state
otherwise, any Contribution intentionally submitted for
inclusion in the Work by You to the Licensor shall be under the
terms and conditions of this License, without any additional
terms or conditions. Notwithstanding the above, nothing herein
shall supersede or modify the terms of any separate license
agreement you may have executed with Licensor regarding such
Contributions.
6. Trademarks. This License does not grant permission to use the
trade names, trademarks, service marks, or product names of the
Licensor, except as required for reasonable and customary use
in describing the origin of the Work and reproducing the content
of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an &quot;AS IS&quot; BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or
conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or
FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for
determining the appropriateness of using or redistributing the
Work and assume any risks associated with Your exercise of
permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and
grossly negligent acts) or agreed to in writing, shall any
Contributor be liable to You for damages, including any direct,
indirect, special, incidental, or consequential damages of any
character arising as a result of this License or out of the use
or inability to use the Work (including but not limited to
damages for loss of goodwill, work stoppage, computer failure or
malfunction, or any and all other commercial damages or losses),
even if such Contributor has been advised of the possibility of
such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by
reason of your accepting any such warranty or additional
liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets &quot;[]&quot;
replaced with your own identifying information. (Don&apos;t include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same &quot;printed page&quot; as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an &quot;AS IS&quot; BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied. See the License for the specific language governing
permissions and limitations under the License.
</codeblock>
</section>
</refbody>
</reference>
@@ -0,0 +1,53 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This document was created with Syntext Serna Free. --><!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd" []>
<!--
**
* Copyright (C) 2006-2010 YUCHENG HU
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* HA WEBSYSTEMS
* http://www.hawebs.net
* http://www.tcivis.com
*
* Contact
* huyuchengus@gmail.com / yuchenghu@hawebs.net
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
* GNU GENERAL PUBLIC LICENSE
* APACHE LICENSE, VERSION 2.0
*
* +++++++++++++++++++++++++++++++++++++++++++++++++
-->
<reference id="rgscopyright" xml:lang="zh">
<title>版权信息</title>
<refbody>
<section>
<p><image href="../../images/halogo.jpg">
<alt>HAWEBS信息技术股份有限公司(LOGO)</alt>
</image></p>
<p>版权所有 2004-2010 软件开发小组</p>
<p>中文参考手册版权所有 2006 - 2010 HAWEBS信息技术有限公司</p>
<p>基于Apache许可证, 版本2.0。你必须在基于许可证的要求下使用本软件,你可以通过下面的链接来获得相关的具体内容 <xref href="http://www.apache.org/licenses/LICENSE-2.0" format="html" scope="external">http://www.apache.org/licenses/LICENSE-2.0</xref>。</p>
</section>
<section>
<title>相关信息</title>
<p><xref format="html" href="http://forums.hawebs.net/computer/" scope="external">OSS 计算技术</xref></p>
<p><xref format="html" href="http://news.hawebs.net/" scope="external">淡远资讯中心</xref></p>
<p><xref format="html" href="http://docs.hawebs.net/xhtml/" scope="external">文档库</xref></p>
<p><xref href="apachelicense.dita#apachelicense"/></p>
</section>
</refbody>
</reference>
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This file is part of the DITA Open Toolkit project hosted on
Sourceforge.net. See the accompanying license.txt file for
applicable licenses.-->
<!-- (c) Copyright IBM Corp. 2005, 2006 All Rights Reserved. -->
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
<task id="proccond" xml:lang="zh">
<title>过滤与标记内容</title>
<shortdesc>You can use metadata on elements to filter or flag content, and
to show revised content.</shortdesc>
<prolog>
<metadata>
<keywords>
<indexterm>filtering content</indexterm>
<indexterm>flagging content</indexterm>
<indexterm>conditional processing</indexterm>
</keywords>
</metadata>
</prolog>
<taskbody></taskbody>
</task>
@@ -0,0 +1,104 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This file is part of the DITA Open Toolkit project hosted on
Sourceforge.net. See the accompanying license.txt file for
applicable licenses.-->
<!-- (c) Copyright IBM Corp. 2005, 2006 All Rights Reserved. -->
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
<task id="showrev" xml:lang="zh">
<title>显示版本</title>
<shortdesc>You can show the revision information for your content. All
revision information is hidden by default.</shortdesc>
<prolog>
<metadata>
<keywords>
<indexterm>metadata attributes<indexterm>showing
revisions</indexterm></indexterm>
<indexterm>revisions<indexterm>showing</indexterm></indexterm>
<indexterm>showing revisions</indexterm>
</keywords>
</metadata>
</prolog>
<taskbody>
<steps>
<step>
<cmd>Create a DITA filter file in the directory you want to add
the file to. Give the file a descriptive name, such as
"audience-flag-build.ditaval".</cmd>
</step>
<step>
<cmd>Open the file, and type below content into it:</cmd>
<tutorialinfo>
<codeblock>&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;val> &lt;/val></codeblock>
</tutorialinfo>
</step>
<step>
<cmd>Define the revision you want to show:</cmd>
<substeps>
<substep>
<cmd>Add a new property for flag by adding a new line
<codeph>&lt;revprop val="" style="" action="" date=""/>"</codeph>.
</cmd>
</substep>
<substep>
<cmd>Type the name of the revision you want to show.</cmd>
<stepxmp>For example, "rev1".</stepxmp>
</substep>
<substep>
<cmd>Enter the date of the revision, or the date it
started or ended.</cmd>
<stepxmp>For example, "05-10-11".</stepxmp>
</substep>
<substep>
<cmd>Define how the revision will be flagged in XHTML:
either by images or colors. </cmd>
<info>
<ul>
<li>Type the value of style if the revision
will be flagged with color, either by using
the RGB codes or color. For example,
"#008040" or "Green". Type the
value of action. For example, "noflag". </li>
<li>Enter the value of action if the revision
will be flagged with image. For example,
"flag".</li>
</ul>
</info>
<info>Use images instead of color to ensure that your
output is flagged consistently and accessibly.
Color only works for flagging phrase-level
information, and can not be distinguishable to
color-blind readers, on monochrome displays, or
once an online page is printed. Note: If both style
and action="flag" are used, the revision will be flagged
by both of them.</info>
</substep>
<substep>
<cmd>Enter the character to use when flagging the
revision in PDF.</cmd>
<stepxmp>For example, "A".</stepxmp>
<info><p><note importance="recommended">Revision indication for PDF output will be specific to
each implementation. See the documentation for your preferred
FO/PDF output transform as to whether conditional markup and
revisions are supported and how.</note></p></info>
</substep>
</substeps>
<info>You need to define a separate property for each revision
you want to show. For example, if you want to show two
revisions, you would need to define each separately.</info>
<info>You can define more properties by following the steps
above. The final ditaval file with the example values should be like this:
<codeblock>&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;val>
&lt;revprop val="rev1" style="Green" action="noflag" date="2005-10-08" />
&lt;revprop val="rev2" action="flag" date="2005-10-10" />
&lt;/val></codeblock> </info>
</step>
<step>
<cmd>When you publish output from the topic or map, specify the
filter file you want by using the parameter
<codeph>/filter:{args.input.valfile}</codeph> for the output options.</cmd>
</step>
</steps>
</taskbody>
</task>
Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB