test for new launcher for java && forgot to add license...

This commit is contained in:
huanghongxun
2015-07-14 17:36:04 +08:00
parent c321cb5f91
commit abb17dd05d
54 changed files with 1558 additions and 1039 deletions

BIN
HMCL/HMCLauncher.exe Normal file

Binary file not shown.

View File

@@ -88,29 +88,30 @@ task proguard(type: proguard.gradle.ProGuardTask, dependsOn: jar) {
configuration 'proguard.pro'
}
/*
task makeExecutable(dependsOn: jar) {
task makeExecutable(dependsOn: jar) << {
ext {
def re = jar.classifier
injar = jar.archivePath
jar.classifier = ''
outjar = jar.archivePath
jar.classifier = re
makeExecutableinjar = jar.archivePath
jar.classifier = ''
makeExecutableoutjar = jar.archivePath
jar.classifier = ''
}
def fos = new FileOutputStream(outjar)
def is = new FileInputStream('')
def read
def loc = new File(project.buildDir, "libs/" + makeExecutableoutjar.getName().substring(0, makeExecutableoutjar.getName().length()-4)+".exe")
def fos = new FileOutputStream(loc)
def is = new FileInputStream(new File(project.buildDir, '../HMCLauncher.exe'))
int read
def bytes = new byte[8192]
while((read = is.read(bytes)) != -1)
fos.write(bytes, 0, read);
is.close()
is = new FileInputStream(injar)
is = new FileInputStream(makeExecutableinjar)
while((read = is.read(bytes)) != -1)
fos.write(bytes, 0, read);
is.close()
fos.close()
}*/
}
/*
launch4j {
launch4jCmd = 'D:\\Develop\\Java\\Launch4j\\launch4j.exe'
supportUrl = 'http://www.mcbbs.net/thread-142335-1-1.html'
@@ -125,7 +126,7 @@ launch4j {
jar = new File(project.buildDir, 'libs/' + mavenGroupId + '-' + mavenVersion + '.jar').absolutePath
outfile = mavenGroupId + '-' + mavenVersion + '.exe'
messagesJreVersionError = 'This application requires a Java Runtime Environment installation, or the runtime is corrupted.\n\u6ca1\u6709\u627e\u5230\u004a\u0061\u0076\u0061\u8fd0\u884c\u65f6\uff0c\u8bf7\u4e0d\u8981\u4f7f\u7528\u7eff\u8272\u004a\u0061\u0076\u0061\uff0c\u8bf7\u4f7f\u7528\u5b89\u88c5\u7248\u7684\u004a\u0061\u0076\u0061\uff0c\u70b9\u51fb\u786e\u5b9a\u8fdb\u5165\u004a\u0061\u0076\u0061\u5b89\u88c5\u9875\u9762\u3002'
}
}*/
processResources {
from(sourceSets.main.resources.srcDirs) {
@@ -133,5 +134,5 @@ processResources {
}
}
build.dependsOn proguard
//build.dependsOn makeExecutable
makeExecutable.dependsOn proguard
build.dependsOn makeExecutable