Updated gradle build files with new syntax, etc.
This commit is contained in:
parent
5562a693a9
commit
3001a4f8f0
5 changed files with 34 additions and 30 deletions
16
README.html
16
README.html
|
@ -217,7 +217,7 @@ code > span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Inf
|
|||
</table>
|
||||
<p>In order to easily incorporate with existing projects, the property keys may be assigned custom values:</p>
|
||||
<div class="sourceCode"><pre class="sourceCode java"><code class="sourceCode java"><span class="fu">@Version</span>(
|
||||
properties = <span class="st">"example.properties"</span>,
|
||||
properties = <span class="st">"example.properties"</span>,
|
||||
majorKey = <span class="st">"example.major"</span>,
|
||||
minorKey = <span class="st">"example.minor"</span>,
|
||||
patchKey = <span class="st">"example.patch"</span>,
|
||||
|
@ -239,27 +239,27 @@ code > span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Inf
|
|||
<div class="sourceCode"><pre class="sourceCode xml"><code class="sourceCode xml"><span class="kw"><dependency></span>
|
||||
<span class="kw"><groupId></span>net.thauvin.erik<span class="kw"></groupId></span>
|
||||
<span class="kw"><artifactId></span>semver<span class="kw"></artifactId></span>
|
||||
<span class="kw"><version></span>0.9.7<span class="kw"></version></span>
|
||||
<span class="kw"><version></span>0.9.6-beta<span class="kw"></version></span>
|
||||
<span class="kw"></dependency></span></code></pre></div>
|
||||
<h3 id="gradle">Gradle</h3>
|
||||
<h4 id="class-generation">Class Generation</h4>
|
||||
<p>To install and run from <a href="https://gradle.org/">Gradle</a>, add the following to the <code>build.gradle</code> file:</p>
|
||||
<pre class="gradle"><code>dependencies {
|
||||
compile 'net.thauvin.erik:semver:0.9.7'
|
||||
compile 'net.thauvin.erik:semver:0.9.6-beta'
|
||||
}</code></pre>
|
||||
<p>The <code>GeneratedVersion</code> class will be automatically created in the <code>build</code> directory upon compiling.</p>
|
||||
<h4 id="class-source-generation">Class & Source Generation</h4>
|
||||
<p>In order to also incorporate the generated source code into the <code>source tree</code>, use the <a href="https://github.com/ewerk/gradle-plugins/tree/master/plugins/annotation-processor-plugin">EWERK Annotation Processor Plugin</a>. Start by addding the following to the very top of the <code>build.gradle</code> file:</p>
|
||||
<pre class="gradle"><code>plugins {
|
||||
id "com.ewerk.gradle.plugins.annotation-processor" version "1.0.2"
|
||||
id "com.ewerk.gradle.plugins.annotation-processor" version "1.0.3"
|
||||
}</code></pre>
|
||||
<p>Then add the following to the <code>build.gradle</code> file:</p>
|
||||
<pre class="gradle"><code>dependencies {
|
||||
compileOnly 'net.thauvin.erik:semver:0.9.7'
|
||||
compileOnly 'net.thauvin.erik:semver:0.9.6-beta'
|
||||
}
|
||||
|
||||
annotationProcessor {
|
||||
library 'net.thauvin.erik:semver:0.9.7'
|
||||
library 'net.thauvin.erik:semver:0.9.6-beta'
|
||||
processor 'net.thauvin.erik.semver.VersionProcessor'
|
||||
// sourcesDir 'src/generated/java'
|
||||
}
|
||||
|
@ -273,8 +273,8 @@ compileJava {
|
|||
<h3 id="kobalt">Kobalt</h3>
|
||||
<p>To install and run from <a href="http://beust.com/kobalt/">Kobalt</a>, add the following to the <code>Build.kt</code> file:</p>
|
||||
<pre class="gradle"><code>dependencies {
|
||||
apt("net.thauvin.erik:semver:0.9.7")
|
||||
compile("net.thauvin.erik:semver:0.9.7")
|
||||
apt("net.thauvin.erik:semver:0.9.6-beta")
|
||||
compile("net.thauvin.erik:semver:0.9.6-beta")
|
||||
}</code></pre>
|
||||
<p>Please look at the <a href="https://github.com/ethauvin/semver/blob/master/example/kobalt/src/Build.kt">Build.kt</a> file in the <a href="https://github.com/ethauvin/semver/tree/master/example">example</a> module directory for a sample.</p>
|
||||
<h3 id="auto-increment">Auto-Increment</h3>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue