Created
August 19, 2014 03:11
-
-
Save johnrengelman/eb3c40f37101ee580214 to your computer and use it in GitHub Desktop.
Shadow & Release plugin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
buildscript { | |
repositories { | |
jcenter() | |
maven { url "https://oss.sonatype.org/content/groups/public"} | |
} | |
dependencies { | |
classpath 'com.github.jengelman.gradle.plugins:shadow:1.0.3' | |
classpath 'com.github.townsfolk:gradle-release:1.2' | |
} | |
} | |
apply plugin: 'java' | |
apply plugin: 'release' | |
apply plugin: 'com.github.johnrengelman.shadow' | |
version '1.0' | |
repositories { | |
jcenter() | |
} | |
dependencies { | |
compile 'com.github.jengelman.gradle.plugins:shadow:1.0.3' | |
runtime 'com.github.townsfolk:gradle-release:1.2' | |
} | |
def versionDependency = "version_dependencies.conf" | |
shadowJar { | |
classifier = '' | |
from versionDependency | |
mergeServiceFiles() | |
} | |
jar { | |
manifest { | |
attributes('Implementation-Title': 'Gradle', | |
'Implementation-Version': version, | |
'Built-By': System.getProperty('user.name'), | |
'Built-Date': new Date(), | |
'Built-JDK': System.getProperty('java.version'), | |
'Class-Path': configurations.runtime.files.collect { it.name }.join(' ')) | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
some conf file |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment