|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 3 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| 4 | + <modelVersion>4.0.0</modelVersion> |
| 5 | + |
| 6 | + <groupId>com.hellokoding</groupId> |
| 7 | + <artifactId>hello-jooq</artifactId> |
| 8 | + <version>0.0.1-SNAPSHOT</version> |
| 9 | + <packaging>jar</packaging> |
| 10 | + |
| 11 | + <name>Hello jOOQ</name> |
| 12 | + <description>Hello jOOQ</description> |
| 13 | + |
| 14 | + <properties> |
| 15 | + <maven.compiler.source>1.7</maven.compiler.source> |
| 16 | + <maven.compiler.target>1.7</maven.compiler.target> |
| 17 | + </properties> |
| 18 | + |
| 19 | + <dependencies> |
| 20 | + <dependency> |
| 21 | + <groupId>mysql</groupId> |
| 22 | + <artifactId>mysql-connector-java</artifactId> |
| 23 | + <version>6.0.3</version> |
| 24 | + </dependency> |
| 25 | + <dependency> |
| 26 | + <groupId>org.jooq</groupId> |
| 27 | + <artifactId>jooq</artifactId> |
| 28 | + <version>3.8.3</version> |
| 29 | + </dependency> |
| 30 | + <dependency> |
| 31 | + <groupId>org.jooq</groupId> |
| 32 | + <artifactId>jooq-meta</artifactId> |
| 33 | + <version>3.8.3</version> |
| 34 | + </dependency> |
| 35 | + <dependency> |
| 36 | + <groupId>org.jooq</groupId> |
| 37 | + <artifactId>jooq-codegen</artifactId> |
| 38 | + <version>3.8.3</version> |
| 39 | + </dependency> |
| 40 | + </dependencies> |
| 41 | + |
| 42 | + <build> |
| 43 | + <plugins> |
| 44 | + <plugin> |
| 45 | + <groupId>org.jooq</groupId> |
| 46 | + <artifactId>jooq-codegen-maven</artifactId> |
| 47 | + <version>3.8.3</version> |
| 48 | + |
| 49 | + <!-- The plugin should hook into the generate goal --> |
| 50 | + <executions> |
| 51 | + <execution> |
| 52 | + <goals> |
| 53 | + <goal>generate</goal> |
| 54 | + </goals> |
| 55 | + </execution> |
| 56 | + </executions> |
| 57 | + |
| 58 | + <dependencies/> |
| 59 | + |
| 60 | + <configuration> |
| 61 | + <jdbc> |
| 62 | + <driver>${jdbc.driver}</driver> |
| 63 | + <url>${jdbc.url}</url> |
| 64 | + <user>${jdbc.user}</user> |
| 65 | + <password>${jdbc.password}</password> |
| 66 | + </jdbc> |
| 67 | + |
| 68 | + <generator> |
| 69 | + <database> |
| 70 | + <name>org.jooq.util.mysql.MySQLDatabase</name> |
| 71 | + <includes>.*</includes> |
| 72 | + <excludes></excludes> |
| 73 | + <inputSchema>library</inputSchema> |
| 74 | + </database> |
| 75 | + <target> |
| 76 | + <packageName>com.hellokoding.jooq.model</packageName> |
| 77 | + <directory>src/main/java</directory> |
| 78 | + </target> |
| 79 | + </generator> |
| 80 | + </configuration> |
| 81 | + </plugin> |
| 82 | + |
| 83 | + <plugin> |
| 84 | + <groupId>org.codehaus.mojo</groupId> |
| 85 | + <artifactId>exec-maven-plugin</artifactId> |
| 86 | + <version>1.5.0</version> |
| 87 | + <executions> |
| 88 | + <execution> |
| 89 | + <goals> |
| 90 | + <goal>exec</goal> |
| 91 | + </goals> |
| 92 | + </execution> |
| 93 | + </executions> |
| 94 | + <configuration> |
| 95 | + <systemProperties> |
| 96 | + <systemProperty> |
| 97 | + <key>jdbc.driver</key> |
| 98 | + <value>${jdbc.driver}</value> |
| 99 | + </systemProperty> |
| 100 | + <systemProperty> |
| 101 | + <key>jdbc.user</key> |
| 102 | + <value>${jdbc.user}</value> |
| 103 | + </systemProperty> |
| 104 | + <systemProperty> |
| 105 | + <key>jdbc.password</key> |
| 106 | + <value>${jdbc.password}</value> |
| 107 | + </systemProperty> |
| 108 | + <systemProperty> |
| 109 | + <key>jdbc.url</key> |
| 110 | + <value>${jdbc.url}</value> |
| 111 | + </systemProperty> |
| 112 | + </systemProperties> |
| 113 | + </configuration> |
| 114 | + </plugin> |
| 115 | + </plugins> |
| 116 | + </build> |
| 117 | + |
| 118 | + <profiles> |
| 119 | + <profile> |
| 120 | + <id>default</id> |
| 121 | + <activation> |
| 122 | + <activeByDefault>true</activeByDefault> |
| 123 | + </activation> |
| 124 | + <properties> |
| 125 | + <jdbc.user>hellokoding</jdbc.user> |
| 126 | + <jdbc.password>hellokoding</jdbc.password> |
| 127 | + <jdbc.url>jdbc:mysql://localhost:3306/library?serverTimezone=UTC</jdbc.url> |
| 128 | + <jdbc.driver>com.mysql.cj.jdbc.Driver</jdbc.driver> |
| 129 | + </properties> |
| 130 | + </profile> |
| 131 | + </profiles> |
| 132 | + |
| 133 | + |
| 134 | +</project> |
0 commit comments