Projekt-Dokumentation (Aktueller Stand von juplo.de) hinzugefĆ¼gt
[website] / dist / hibernate4-maven-plugin-1.0.2 / skip.html
1 <!DOCTYPE html>
2 <!-- Generated by Apache Maven Doxia Site Renderer 1.4 at 2014-04-29 -->
3                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               <!-- Current: skip.html -->
4 <!-- Active: index.html -->
5 <!-- Path: [index.html, skip.html] -->
6 <!-- Skiplist: [index.html, configuration.html, export-mojo.html, debugging.html, skip.html, force.html, pitfalls.html] -->
7 <html>
8   <head>
9     <title>juplo - Hibernate 4 Maven Plugin - Skipping Execution</title>
10     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
11     <link rel="canonical" href="http://juplo.de/hibernate4-maven-plugin/skip.html"/>
12     <link rel="stylesheet" type="text/css" href="/css/base.css" />
13     <style type="text/css">
14       @import '/css/screen.css' screen and (min-width: 960px);
15       @import '/css/phone.css' screen and (max-width: 599px);
16       @import '/css/tiny.css' screen and (max-width: 399px);
17     </style>
18     <script src="/js/base.js"></script>
19     <!--[if IE 8]>
20       <script src="/js/ie8.js"></script>
21     <![endif]-->
22     <!--[if IE 7]>
23       <script src="/js/ie7.js"></script>
24     <![endif]-->
25     <!--[if lt IE 7]>
26       <script src="/js/ie6.js"></script>
27     <![endif]-->
28     <meta name="author" content="Kai Moritz" />
29     <meta name="Date-Revision-yyyymmdd" content="20140429" />
30     <meta http-equiv="Content-Language" content="en" />
31         
32   </head>
33   <body onload="prettyPrint()">
34     <div id="page">
35       <header id="header">
36         <a href="/" title="Home" id="logo">juplo</a>
37         <span id="slogan"><strong>Java</strong> bits from nerds for nerds</span>
38         <hr class="h" />
39       </header>
40       <div id="breadcrumb">
41         <strong class="b title">You are here:</strong>
42         <ol class="b">
43           <li class="b"><a class="b" href="/">Home</a></li>
44           <li class="b"><a class="b" href="/projects.html">Projects</a></li>
45                       <li class="b"><a class="b" href="./index.html">Hibernate 4 Maven Plugin</a </li>
46                         <li class="b"><strong class="b">Skipping Execution</strong></li>
47                   </ol>
48         <a class="hide" href="#navigation">Jump to navigation</a>
49         <div class="b"></div>
50       </div>
51       <div class="fc cols_2">
52         <div class="content cf">
53           <section id="content" class="main">
54             <h1>Hibernate 4 Maven Plugin - Skipping Execution</h1>
55             <p>In most use-cases, the hibernate4-maven-plugin is used to create a test-database automatically. In this use-cases, it is very likely, that it will result in mistakes/errors, if the goal is executed, when the tests are skipped. For example, one might manually overwrite the database-url with the url of the production-database, in order to run other tests, like starting a local webserver with the <a class="externalLink" href="http://wiki.eclipse.org/Jetty/Feature/Jetty_Maven_Plugin">jetty-maven-plugin</a>. If the export-goal would be executed in such a scenario, it might erase the hole production-database, which is not very desireable.</p>
56 <p>Because of this, the configuration-parameter <tt>skip</tt> defaults to the value of the proptery <tt>maven.test.skip</tt>. This way, the execution of the hibernate4-maven-plugin is skipped automatically, when the tests are skipped. Think of it as a build-in security-belt.</p>
57 <p>If you do not like that, because you need the plugin to always execute the export-goal, even if the tests are skipped you can configure that explicitly, by setting the configuration-parameter <tt>skip</tt> to false:</p>
58 <div>
59 <pre>&lt;plugin&gt;
60   &lt;groupId&gt;de.juplo&lt;/groupId&gt;
61   &lt;artifactId&gt;hibernate4-maven-plugin&lt;/artifactId&gt;
62   ...
63   &lt;configuration&gt;
64     &lt;skip&gt;false&lt;/skip&gt;
65   &lt;/configuration&gt;
66 &lt;/plugin&gt;</pre></div>
67 <p>Or, if you want the export-goal to be executed by default and to be skipped if you say so, you can bind the value of the configuration-parameter <tt>skip</tt> to a custom property. For example:</p>
68 <div>
69 <pre>&lt;plugin&gt;
70   &lt;groupId&gt;de.juplo&lt;/groupId&gt;
71   &lt;artifactId&gt;hibernate4-maven-plugin&lt;/artifactId&gt;
72   ...
73   &lt;configuration&gt;
74     &lt;skip&gt;${foo.bar}&lt;/skip&gt;
75   &lt;/configuration&gt;
76 &lt;/plugin&gt;</pre></div>
77 <p>This way, the export-goal would be skipped, if you set the property <tt>foo.bar</tt> to <tt>true</tt>. For example, if you specify <tt>-Dfoo.bar=true</tt> on the command-line.</p>
78           </section>
79           <div class="marginal">
80             <nav id="nav">
81               <hr />
82               <a id="navigation"></a>
83               <h2 class="nav menu">Section-Menu</h2>
84               <ul id="menu">
85                 <li class="m blog"><a href="/blog/" class="m">Blog</a></li>
86                 <li class="m projects"><a href="/projects.html" class="m selected">Projects</a></li>
87               </ul>
88               <h2 class="nav submenu">
89                 <span class="s">Submenu for section</span>
90                 <a class="s selected" href="/projects.html">Projects</a>
91               </h2>
92               <ul id="submenu" class="s">
93                                                                       <li class="s sub">
94                                               <a class="s selected" href="./index.html">Hibernate 4 Maven Plugin</a>
95                                             <ul class="s active">
96                                                                                                                                                                                                                                                                           <li class="s">
97                     <a href="configuration.html" class="s" title="Configuration Examples">Configuration Examples</a>
98                 </li>
99                                                                                                                       <li class="s">
100                     <a href="export-mojo.html" class="s" title="Parameter Documentation">Parameter Documentation</a>
101                 </li>
102                                                                                                                       <li class="s">
103                     <a href="debugging.html" class="s" title="Enable Debug-Output">Enable Debug-Output</a>
104                 </li>
105                                                                                                                             <li class="s">
106               <strong class="s">Skipping Execution</strong>
107                 </li>
108                                                                                                                       <li class="s">
109                     <a href="force.html" class="s" title="Force Exceution">Force Exceution</a>
110                 </li>
111                                                                                                                       <li class="s">
112                     <a href="pitfalls.html" class="s" title="Known Pitfalls (FAQ)">Known Pitfalls (FAQ)</a>
113                 </li>
114                                                                                                                                                                                                                                                                                                                                                                   <li class="s sub">
115                     <a href="project-info.html" class="s" title="Project Information">Project Information</a>
116                 </li>
117                                                                                                                                                                                                       <li class="s sub">
118                     <a href="project-reports.html" class="s" title="Project Reports">Project Reports</a>
119                 </li>
120                                                                                                       </ul>
121                     </li>
122                                                 </ul>
123               <hr />
124             </nav>
125             <p>
126               <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy">
127                 <img class="poweredBy" alt="Built by Maven" src="./images/logos/maven-feather.png" />
128               </a>
129             </p>
130           </div>
131         </div>
132       </div>
133       <footer id="footer">
134         <hr />
135         <ul id="footerlinks">
136           <li class="f" id="copyright">&#xa9; <strong>mo</strong>             2014
137       </li>
138         </ul>
139       </footer>
140     </div>
141         <script type="text/javascript"><!--//--><![CDATA[//><!--
142       var _gaq = _gaq || [];
143       _gaq.push(['_setAccount', 'UA-571104-3']);
144       _gaq.push(['_trackPageview']);
145       (function() {
146         var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
147         ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
148         var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
149       })();
150     //--><!]]>
151       </body>
152 </html>