Skip to content

Commit

Permalink
Removing some unnecessary lines
Browse files Browse the repository at this point in the history
  • Loading branch information
langmo committed Mar 19, 2020
1 parent 26bc907 commit eef0fe9
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions examples/extended/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,15 @@ plugins {
// Apply the gradlensis plugin to add support for generating Windows installers
id "com.github.langmo.gradlensis" version "0.1.0"
}
// Set JVM compatibility mode to Java 1.7. Always a good idea to use older bytecode versions
// on Windows machines...
allprojects {
tasks.withType(JavaCompile) {
sourceCompatibility = '1.7'
targetCompatibility = '1.7'
}
}
// Allow JAR file to be directly executed.
jar {
manifest {
attributes(
Expand Down Expand Up @@ -41,8 +44,6 @@ launch4j {
cmdLine = ""
chdir = '.'
priority = 'normal'
downloadUrl = "http://java.com/download"
supportUrl = 'http://www.youscope.org'
stayAlive = false
restartOnCrash = false
manifest = ""
Expand All @@ -53,6 +54,7 @@ launch4j {
bundledJreAsFallback = false
jreMinVersion = "1.7.0"
}

// Task to create the 64 bit version of startup EXE
createExe {
outfile = 'Example64.exe'
Expand Down Expand Up @@ -91,22 +93,31 @@ distributions {
}
}

// Common configuration for both installers.
nsis {
configuration = file("${rootProject.projectDir}/extended.nsi")
runIn = file("${rootProject.buildDir}/install/nsis/")
}

// Specific configuration for 64bit installer
createInstaller {
variables = ['WIN64':'True']
}
createInstaller.dependsOn installNsisDist

// Specific configuration for 32bit installer
task createInstaller32(type: com.github.langmo.gradlensis.GradleNsisTask) {
variables = ['WIN32':'True']
}
createInstaller.dependsOn installNsisDist
createInstaller32.dependsOn installNsisDist

// Task to create both installers.
task createInstallers {
dependsOn ":createInstaller32"
dependsOn ":createInstaller"
}

// Add metadata for tasks such that they appear when calling gradlew tasks
def NSIS_GROUP = 'nsis'
createInstaller32.group = createInstaller.group
createInstaller32.description = createInstaller.description
Expand Down

0 comments on commit eef0fe9

Please sign in to comment.