summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimonIT <simonit.orig@gmail.com>2019-11-26 22:58:08 +0100
committerSimonIT <simonit.orig@gmail.com>2019-11-26 22:58:08 +0100
commit077d0afcaf218db35553dbb4fdf764e276c00ba7 (patch)
treebe5b119502ec9eddec3bc35daeb910106c34e779
parentc644272e3be0c8e2a3b04595ec2249ed4e76e56e (diff)
downloadgdx-boardgame-077d0afcaf218db35553dbb4fdf764e276c00ba7.zip
gdx-boardgame-077d0afcaf218db35553dbb4fdf764e276c00ba7.tar.gz
make this framework deliver source and javadoc jars, renamed build to generateAssets task because of custom build tasks are not allowed when using the standard Gradle lifecycle plugins
-rw-r--r--README.md1
-rw-r--r--assets/build.gradle6
-rw-r--r--build.gradle16
3 files changed, 20 insertions, 3 deletions
diff --git a/README.md b/README.md
index 928bdce..2006aea 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,5 @@
# gdx-boardgame
+[![](https://jitpack.io/v/jeremyz/gdx-boardgame.svg)](https://jitpack.io/#jeremyz/gdx-boardgame)
is a [libgdx](https://libgdx.badlogicgames.com/) based framework to build 2D boardgames.
diff --git a/assets/build.gradle b/assets/build.gradle
index 4b37476..cf35be1 100644
--- a/assets/build.gradle
+++ b/assets/build.gradle
@@ -6,7 +6,7 @@ dependencies {
texturePacker "com.badlogicgames.gdx:gdx-tools:$gdxVersion"
}
-defaultTasks 'build'
+defaultTasks 'generateAssets'
task packLoading(type: JavaExec) {
main = 'com.badlogic.gdx.tools.texturepacker.TexturePacker'
@@ -20,10 +20,10 @@ task packHexOverlays(type: JavaExec) {
args = ['hex-overlays', 'data', 'hex-overlays']
}
-task build() {
+task generateAssets() {
description "Builds the skin at various DPIs"
}
-build.dependsOn {
+generateAssets.dependsOn {
tasks.findAll { task -> task.name.startsWith('pack') }
}
diff --git a/build.gradle b/build.gradle
index 090f805..5522d34 100644
--- a/build.gradle
+++ b/build.gradle
@@ -42,10 +42,26 @@ project(":test") {
project(":core") {
apply plugin: "java"
+ apply plugin: "maven"
dependencies {
implementation "com.badlogicgames.gdx:gdx:$gdxVersion"
}
+
+ task sourcesJar(type: Jar, dependsOn: classes) {
+ classifier = 'sources'
+ from sourceSets.main.allSource
+ }
+
+ task javadocJar(type: Jar, dependsOn: javadoc) {
+ classifier = 'javadoc'
+ from javadoc.destinationDir
+ }
+
+ artifacts {
+ archives sourcesJar
+ archives javadocJar
+ }
}
project(":assets") {