Permalink
Browse files

* dried up pom.xml - build tag was redundant

* added profile to be able to skip a database via command line switch, like sqlserver

* [do_sqlite3] put the correct groupId and artifactId in place so everything gets downloaded
from the maven remote repostory
  • Loading branch information...
1 parent efe4034 commit 71b0020bba88ff1523c6688fcee0aaf7b32e48b4 @mkristian mkristian committed Nov 4, 2009
Showing with 219 additions and 141 deletions.
  1. +63 −0 MAVEN.markdown
  2. +8 −14 do_derby/pom.xml
  3. +16 −14 do_h2/pom.xml
  4. +16 −14 do_hsqldb/pom.xml
  5. +9 −14 do_mysql/pom.xml
  6. +16 −14 do_oracle/pom.xml
  7. +16 −14 do_postgres/pom.xml
  8. +18 −17 do_sqlite3/pom.xml
  9. +34 −14 do_sqlserver/pom.xml
  10. +23 −26 pom.xml
View
@@ -0,0 +1,63 @@
+how to use maven
+================
+
+maven is optional and complementary to the rake build process whioch works with MRI and JRUBY.
+
+install maven
+-------------
+
+maven.apache.org explains how to install maven.
+
+maven goals
+===========
+
+you can execute maven in the project root directory or in any of its subdirectories.
+
+mvn install
+-----------
+
+builds all the jar files, run all specs and installs them in the local maven repository.
+
+mvn test
+--------
+
+will run all specs !!
+
+command line switches
+---------------------
+
+all command line switches work for both the test as well the install goal.
+
+to skip all specs execute
+
+mvn install -DskipSpecs=true
+
+to exclude one or the other database call
+
+mvn install -P skip_oracle,skip_sqlserver
+
+to have the reactor run over all subdirectories add the fail-at-end flag
+
+mvn install -fae
+
+
+mvn checkstyle:checkstyle
+-------------------------
+
+just prints out all the style 'errors' for each subdirectory into the console
+
+mvn findbugs:findbugs
+---------------------
+
+this goal produces a html page which can be viewed by something like
+
+firefox target/site/findbugs.html &
+
+switching jruby version
+=======================
+
+without any extra arguments the jruby version is the default from the rails-maven-plugin, but with an extra argument
+
+-Djruby.version=1.4.0
+
+maven downloads (if needed) the respective jruby version and uses it.
View
@@ -11,20 +11,6 @@
<packaging>jar</packaging>
<name>do_derby</name>
<description>A DataObjects.rb driver for Derby</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
@@ -37,4 +23,12 @@
<version>10.5.3.0_1</version>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_derby</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
View
@@ -11,30 +11,32 @@
<packaging>jar</packaging>
<name>do_h2</name>
<description>A DataObjects.rb driver for H2</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
+
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
<artifactId>do_jdbc</artifactId>
<version>${pom.parent.version}</version>
</dependency>
<dependency>
+ <groupId>${pom.parent.groupId}</groupId>
+ <artifactId>do_jdbc</artifactId>
+ <version>${pom.parent.version}</version>
+ <type>test-jar</type>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<version>1.1.117</version>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_h2</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
View
@@ -11,30 +11,32 @@
<packaging>jar</packaging>
<name>do_hsqldb</name>
<description>A DataObjects.rb driver for HSQLDB</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
+
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
<artifactId>do_jdbc</artifactId>
<version>${pom.parent.version}</version>
</dependency>
<dependency>
+ <groupId>${pom.parent.groupId}</groupId>
+ <artifactId>do_jdbc</artifactId>
+ <version>${pom.parent.version}</version>
+ <type>test-jar</type>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>hsqldb</groupId>
<artifactId>hsqldb</artifactId>
<version>1.8.0.7</version>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_hsqldb</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
View
@@ -11,20 +11,7 @@
<packaging>jar</packaging>
<name>do_mysql</name>
<description>A DataObjects.rb driver for MySQL</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
+
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
@@ -38,4 +25,12 @@
<version>5.0.4</version>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_mysql</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
View
@@ -11,30 +11,32 @@
<packaging>jar</packaging>
<name>do_oracle</name>
<description>A DataObjects.rb driver for Oracle</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
+
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
<artifactId>do_jdbc</artifactId>
<version>${pom.parent.version}</version>
</dependency>
<dependency>
+ <groupId>${pom.parent.groupId}</groupId>
+ <artifactId>do_jdbc</artifactId>
+ <version>${pom.parent.version}</version>
+ <type>test-jar</type>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc14</artifactId>
<version>10.2.0.3.0</version>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_oracle</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
View
@@ -11,30 +11,32 @@
<packaging>jar</packaging>
<name>do_postgres</name>
<description>A DataObjects.rb driver for PostgreSQL</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
+
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
<artifactId>do_jdbc</artifactId>
<version>${pom.parent.version}</version>
</dependency>
<dependency>
+ <groupId>${pom.parent.groupId}</groupId>
+ <artifactId>do_jdbc</artifactId>
+ <version>${pom.parent.version}</version>
+ <type>test-jar</type>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>8.3-603.jdbc3</version>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_postgres</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
View
@@ -11,20 +11,7 @@
<packaging>jar</packaging>
<name>do_sqlite3</name>
<description>A DataObjects.rb driver for SQLite3</description>
- <build>
- <outputDirectory>pkg/classes</outputDirectory>
- <sourceDirectory>ext-java/src/main/java</sourceDirectory>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- </plugins>
- </build>
+
<dependencies>
<dependency>
<groupId>${pom.parent.groupId}</groupId>
@@ -39,9 +26,23 @@
<scope>test</scope>
</dependency>
<dependency>
- <groupId>org.sqlite</groupId>
- <artifactId>sqlite3</artifactId>
- <version>3.5.8</version>
+ <groupId>org.xerial</groupId>
+ <artifactId>sqlite-jdbc</artifactId>
+ <version>3.6.10</version>
+ <exclusions>
+ <exclusion>
+ <groupId>org.xerial.thirdparty</groupId>
+ <artifactId>nestedvm</artifactId>
+ </exclusion>
+ </exclusions>
</dependency>
</dependencies>
+ <profiles>
+ <profile>
+ <id>skip_sqlite3</id>
+ <properties>
+ <skipSpecs>true</skipSpecs>
+ </properties>
+ </profile>
+ </profiles>
</project>
Oops, something went wrong.

0 comments on commit 71b0020

Please sign in to comment.