Browse Source

Use git-version plugin.

pull/31/head
Chris Smith 9 years ago
parent
commit
db036b4928
1 changed files with 5 additions and 12 deletions
  1. 5
    12
      build.gradle

+ 5
- 12
build.gradle View File

@@ -1,14 +1,9 @@
1
-import org.mdonoughe.JGitDescribeTask
2
-
3
-def jgit = new org.mdonoughe.JGitDescribeTask()
4
-jgit.setDir(new File("$projectDir", '.git'))
5
-project.version = jgit.getDescription() + '-SNAPSHOT'
1
+group = 'com.dmdirc'
6 2
 
3
+apply plugin: 'com.dmdirc.git-version'
7 4
 apply plugin: 'java'
8 5
 apply plugin: 'maven-publish'
9 6
 
10
-group = 'com.dmdirc'
11
-
12 7
 sourceSets {
13 8
     main {
14 9
         java.srcDirs = ['src']
@@ -62,13 +57,11 @@ task publishSnapshot(dependsOn: 'publishMavenJavaPublicationToSnapshotsRepositor
62 57
 buildscript {
63 58
     repositories {
64 59
         mavenCentral()
65
-        maven {
66
-            url 'http://artifactory.dmdirc.com/artifactory/repo'
67
-        }
60
+        maven { url 'http://artifactory.dmdirc.com/artifactory/repo' }
61
+        maven { url 'https://dl.bintray.com/dmdirc/releases/' }
68 62
     }
69 63
 
70 64
     dependencies {
71
-        classpath group: 'com.github.shanemcc', name: 'jgit-describe', version: '0.5'
72
-        classpath group: 'org.eclipse.jgit', name: 'org.eclipse.jgit', version: '2.3.1.+'
65
+        classpath group: 'com.dmdirc', name: 'git-version', version: '1.0'
73 66
     }
74 67
 }

Loading…
Cancel
Save