Skip to content

Commit

Permalink
Fixed a number of typos (thanks to sguillory), moved to forge-parent …
Browse files Browse the repository at this point in the history
…2 instead of 2-SNAPSHOT
  • Loading branch information
Tim O'Brien committed Aug 22, 2008
1 parent 4eff0b5 commit e38bd47
Show file tree
Hide file tree
Showing 7 changed files with 50 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ $ <command>mvn exec:java -Dexec.mainClass=com.sonatype.maven.weather.Main</comma
[INFO] \- junit:junit:jar:3.8.1:test
...</screen>

<para>If you're truely adventurous or want to see the full dependency
<para>If you're truly adventurous or want to see the full dependency
trail, including artifacts that were rejected due to conflicts and other
reasons, run Maven with the debug flag.</para>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@
class. Atmospheric conditions such as the humidity, maximum visibility,
barometric pressure, and whether the pressure is rising or falling is
stored in an <classname>Atmosphere</classname> class. A textual
description of conditions, the temperature, and the data of the
description of conditions, the temperature, and the date of the
observation is stored in a <classname>Condition</classname> class.</para>

<figure>
Expand Down Expand Up @@ -1455,7 +1455,7 @@ class="org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBea
an existing database, you would use an implementation of
jdbcconfiguration. In this case, we're simply using an existing
annotated object model to generate a database. In other words, we have
out Hibernate mapping, but we don't yet have a database. In this usage
our Hibernate mapping, but we don't yet have a database. In this usage
scenario, the appropriate implementation value is
annotationconfiguration. The Maven Hibernate3 Plugin is discussed in
more detail in <xref linkend="sect-spring-running-web" />.</para>
Expand Down Expand Up @@ -2223,7 +2223,7 @@ public class Main {
<para>The <classname>Main</classname> class has a reference to
<classname>WeatherDAO</classname>, <classname>LocationDAO</classname>, and
<classname>WeatherService</classname>. The static
<methodname>main()</methodname> method in this class: </para>
<methodname>main()</methodname> method in this class:</para>

<itemizedlist>
<listitem>
Expand Down Expand Up @@ -2417,7 +2417,7 @@ ${location.country}
bytecode into a single <acronym>JAR</acronym> in
<filename>target/</filename> named
<filename>simple-command-jar-with-dependencies.jar</filename>. This "uber"
<acronym>JAR</acronym> weighs in at 15 MB. </para>
<acronym>JAR</acronym> weighs in at 15 MB.</para>

<para>Before you run the command-line tool, you will need to invoke the
<varname>hbm2ddl</varname> goal of the Hibernate3 plugin to create the
Expand Down Expand Up @@ -2577,4 +2577,4 @@ Evanston, IL, US
Maven projects.</para>
</section>
</section>
</chapter>
</chapter>
32 changes: 15 additions & 17 deletions content/src/main/resources/docbook/en/chapter-optimizing.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@
chapter, we take a step back from the examples you've seen in <xref
linkend="part-example" />, and we ask ourselves if there are any
optimizations that might make more sense given what we now know of Maven.
Maven is a very capable and tool which can be as simple or as complex as
you need it to be. Because of this, there are often a million ways to
accomplish the same task, and there is often no one, "right" way to
configure your Maven project.</para>
Maven is a capable tool which can be as simple or as complex as you need
it to be. Because of this, there are often a million ways to accomplish
the same task, and there is often no one, "right" way to configure your
Maven project.</para>

<para>Don't misinterpret that last sentence as a license to go off and ask
Maven to do something it wasn't designed for. While Maven allows for a
Expand Down Expand Up @@ -88,7 +88,7 @@
second pattern of duplication to note is that sometimes several
dependencies are related and share the same version. This is often the
case when a project's release consists of several closely coupled
component. For example, look at the dependencies on
components. For example, look at the dependencies on
<varname>hibernate-annotations</varname> and
<varname>hibernate-commons-annotations</varname>, both are listed as
version <varname>3.3.0.ga</varname>, and we can expect the version of both
Expand Down Expand Up @@ -354,14 +354,13 @@
the <acronym>HSQLDB</acronym> dependencies duplicated in several places.
Unfortunately, <sgmltag>dependencyManagement</sgmltag> doesn’t apply to
plugin dependencies, but we can still use a property to consolidate the
versions. Most complex Maven multi-module projects tend to define all
version in the top-level <acronym>POM</acronym>. This top-level
<acronym>POM</acronym> then becomes a focal point for changes that affect
the entire project. Think of version numbers as string literals in a Java
class, if you are constantly repeating a literal, you'll likely want to
make it a variable so that when it needs to be change, you only have to
change it in one place. Rolling up the version of
<acronym>HSQLDB</acronym> into a property in the top-level
versions. Most complex Maven multi-module projects declare all versions in
the top-level <acronym>POM</acronym> making the top-level POM a focal
point for changes that affect the entire project. Think of version numbers
as string literals in a Java class, if you are constantly repeating a
literal, you'll likely want to make it a variable so that when it needs to
be change, you only have to change it in one place. Rolling up the version
of <acronym>HSQLDB</acronym> into a property in the top-level
<acronym>POM</acronym> yields the following properties element:</para>

<programlisting language="xml">&lt;project&gt;
Expand Down Expand Up @@ -561,8 +560,7 @@
project's version of Hibernate, listing the
<varname>persistence-api</varname> dependency version near the Hibernate
dependency version will make it more obvious later when your team modifies
the parent <acronym>POM</acronym> to upgrade the Hibernate version.
</para>
the parent <acronym>POM</acronym> to upgrade the Hibernate version.</para>

<para>If you look at the <varname>dependency:analyze</varname> output from
the <varname>simple-web</varname> module, you will see that we also need
Expand Down Expand Up @@ -599,7 +597,7 @@
that the Velocity and Servlet API dependencies are listed in this list for
the simple-web module. This is also expected because, while the project
doesn't have any direct references to the classes of these artifacts, they
are still essential during runtime. </para>
are still essential during runtime.</para>

<para>Be careful when removing any Unused, Declared Dependencies unless
you have very good test coverage, or you might introduce a runtime error.
Expand Down Expand Up @@ -1065,4 +1063,4 @@
should be moved up. The used and unused dependencies list changes over
time and can easily be cleaned up with the Maven Dependency Plugin</para>
</section>
</chapter>
</chapter>
20 changes: 10 additions & 10 deletions content/src/main/resources/docbook/en/chapter-pom-relationships.xml
Original file line number Diff line number Diff line change
Expand Up @@ -142,11 +142,10 @@

<para>Before we dive into some examples of <acronym>POM</acronym>s,
let's take a quick look at the Super <acronym>POM</acronym>. All Maven
project <acronym>POM</acronym>s extend this Super
<acronym>POM</acronym>, it defines a set of defaults shared by all
projects. This Super <acronym>POM</acronym> is a part of the Maven
installation, and can be found in the
<filename>maven-2.0.9-uber.jar</filename> file in
project <acronym>POM</acronym>s extend the Super <acronym>POM</acronym>
which defines a set of defaults shared by all projects. This Super
<acronym>POM</acronym> is a part of the Maven installation, and can be
found in the <filename>maven-2.0.9-uber.jar</filename> file in
<filename>${M2_HOME}/lib</filename>. If you look in this
<acronym>JAR</acronym> file, you will find a file named
<filename>pom-4.0.0.xml</filename> under the
Expand Down Expand Up @@ -1538,10 +1537,11 @@ top-group/project-c/pom.xml</programlisting>
<para>The projects are related to one another because
<varname>top-group</varname> and <varname>sub-group</varname> are
referencing <varname>sub-modules</varname> in a <acronym>POM</acronym>.
For example, the <varname>org.sonatype.mavenbook:top-group</varname> project
is a multi-module project with packaging of type <varname>pom</varname>.
<varname>top-group</varname>'s <filename>pom.xml</filename> would
include the following modules element:</para>
For example, the <varname>org.sonatype.mavenbook:top-group</varname>
project is a multi-module project with packaging of type
<varname>pom</varname>. <varname>top-group</varname>'s
<filename>pom.xml</filename> would include the following modules
element:</para>

<example>
<title>top-group modules element</title>
Expand Down Expand Up @@ -2112,4 +2112,4 @@ top-group/project-c/pom.xml</programlisting>
</section>
</section>
</section>
</chapter>
</chapter>
10 changes: 6 additions & 4 deletions content/src/main/resources/docbook/en/chapter-public-preface.xml
Original file line number Diff line number Diff line change
Expand Up @@ -215,10 +215,12 @@
<para>Sonatype would like to thank the following contributors. The people
listed below have provide feedback which has helped improve the quality of
this book. Thanks to Marcus Biel, Brian Dols, Mangalaganesh
Balasubramanian, and Mark Stewart. Special thanks to Joel Costigliola for
helping to debug and correct the Spring web chapter. Special thanks to
Richard Coasby of Bamboo for acting as the provisional grammar
consultant.</para>
Balasubramanian, Marius Kruger, and Mark Stewart. Special thanks to Joel
Costigliola for helping to debug and correct the Spring web chapter. Stan
Guillory was practically a contributing author given the number of
corrections he posted to the book's Get Satisfation. Thank you Stan.
Special thanks to Richard Coasby of Bamboo for acting as the provisional
grammar consultant.</para>

<para>Thanks to our contributing authors including Eric Redmond.</para>
</section>
Expand Down
18 changes: 10 additions & 8 deletions examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,16 @@
<properties>
<sonatype.site>file:///var/www/domains/sonatype.com/www/htdocs/</sonatype.site>
</properties>
<repository>
<id>sonatype-forge</id>
<name>Sonatype Forge</name>
<url>http://repository.sonatype.com/groups/public</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repositories>
<repository>
<id>sonatype-forge</id>
<name>Sonatype Forge</name>
<url>http://repository.sonatype.com/groups/public</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
</profile>
</profiles>

Expand Down
4 changes: 3 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>org.sonatype.forge</groupId>
<artifactId>forge-parent</artifactId>
<version>2-SNAPSHOT</version>
<version>2</version>
</parent>
<groupId>org.sonatype.mavenbook</groupId>
<artifactId>book</artifactId>
Expand All @@ -26,6 +26,7 @@
<properties>
<sonatype.site>scp://www.sonatype.com/var/www/domains/sonatype.com/www/htdocs/</sonatype.site>
</properties>
<repositories>
<repository>
<id>sonatype-forge</id>
<name>Sonatype Forge</name>
Expand All @@ -34,6 +35,7 @@
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
</profile>
</profiles>

Expand Down

0 comments on commit e38bd47

Please sign in to comment.