core js files and also in the closure-compiler.
+
+ sourceCompatibility = compile_source_compatibility
+ targetCompatibility = compile_target_compatibility
+ options.compilerArgs = additional_compiler_args
+ options.encoding = "UTF-8"
- sourceCompatibility = compile_source_compatibility
- targetCompatibility = compile_target_compatibility
- options.compilerArgs = additional_compiler_args
print ("Setting target compatibility to "+targetCompatibility+"\n")
}
print ("Setting target compatibility to "+targetCompatibility+"\n")
}
+tasks.withType(JavaCompile) {
+ options.encoding = 'UTF-8'
+}
+
+
clean {
doFirst {
delete getdownWebsiteDir
clean {
doFirst {
delete getdownWebsiteDir
eclipseProduct = "${eclipseRoot}/Contents/Eclipse/.eclipseproduct"
} else if (OperatingSystem.current().isWindows()) { // check these paths!!
if (file("${eclipseRoot}/eclipse").isDirectory() && file("${eclipseRoot}/eclipse/.eclipseproduct").exists()) {
eclipseProduct = "${eclipseRoot}/Contents/Eclipse/.eclipseproduct"
} else if (OperatingSystem.current().isWindows()) { // check these paths!!
if (file("${eclipseRoot}/eclipse").isDirectory() && file("${eclipseRoot}/eclipse/.eclipseproduct").exists()) {
- eclipseRoot += "/eclipse.exe"
+ eclipseRoot += "/eclipse"
- eclipseBinary = "${eclipseRoot}/eclipse"
+ eclipseBinary = "${eclipseRoot}/eclipse.exe"
eclipseProduct = "${eclipseRoot}/.eclipseproduct"
} else { // linux or unix
if (file("${eclipseRoot}/eclipse").isDirectory() && file("${eclipseRoot}/eclipse/.eclipseproduct").exists()) {
eclipseRoot += "/eclipse"
eclipseProduct = "${eclipseRoot}/.eclipseproduct"
} else { // linux or unix
if (file("${eclipseRoot}/eclipse").isDirectory() && file("${eclipseRoot}/eclipse/.eclipseproduct").exists()) {
eclipseRoot += "/eclipse"
+println("eclipseDir exists")
}
eclipseBinary = "${eclipseRoot}/eclipse"
eclipseProduct = "${eclipseRoot}/.eclipseproduct"
}
eclipseBinary = "${eclipseRoot}/eclipse"
eclipseProduct = "${eclipseRoot}/.eclipseproduct"
def coreBottom = file(suffixFile)
coreFile.getParentFile().mkdirs()
coreFile.createNewFile()
def coreBottom = file(suffixFile)
coreFile.getParentFile().mkdirs()
coreFile.createNewFile()
- coreFile.write( coreTop.text )
+ coreFile.write( coreTop.getText("UTF-8") )
list.each {
f ->
if (f.exists()) {
list.each {
f ->
if (f.exists()) {
+ def t = f.getText("UTF-8")
t.replaceAll("Clazz\\.([^_])","Clazz_${1}")
coreFile.append( t )
} else {
t.replaceAll("Clazz\\.([^_])","Clazz_${1}")
coreFile.append( t )
} else {
logOutFile.append(msg+"\n")
}
}
logOutFile.append(msg+"\n")
}
}
- coreFile.append( coreBottom.text )
+ coreFile.append( coreBottom.getText("UTF-8") )
msg = "Generating ${zjsfile}"
println(msg)
msg = "Generating ${zjsfile}"
println(msg)
def logErrFOS = logOutFOS
javaexec {
def logErrFOS = logOutFOS
javaexec {
- classpath = files(["${jalviewDir}/tools/closure_compiler.jar"])
- args = [ "--js", jsfile, "--js_output_file", zjsfile ]
+ classpath = files(["${jalviewDir}/${jalviewjs_closure_compiler}"])
+ main = "com.google.javascript.jscomp.CommandLineRunner"
+ jvmArgs = [ "-Dfile.encoding=UTF-8" ]
+ args = [ "--compilation_level", "SIMPLE_OPTIMIZATIONS", "--warning_level", "QUIET", "--charset", "UTF-8", "--js", jsfile, "--js_output_file", zjsfile ]
maxHeapSize = "2g"
msg = "\nRunning '"+commandLine.join(' ')+"'\n"
maxHeapSize = "2g"
msg = "\nRunning '"+commandLine.join(' ')+"'\n"
-org.gradle.jvmargs=-Xmx1536m -Xms512m
+org.gradle.jvmargs=-Xmx1536m -Xms512m -Dfile.encoding=UTF-8
+#systemProp.file.encoding=UTF-8
jalviewjs_j2s_transpile_stdout = j2s-transpile.out
#jalviewjs_j2s_stderr = j2s-transpile.err # all going into out
jalviewjs_j2s_to_console = true
jalviewjs_j2s_transpile_stdout = j2s-transpile.out
#jalviewjs_j2s_stderr = j2s-transpile.err # all going into out
jalviewjs_j2s_to_console = true
+jalviewjs_closure_compiler = tools/closure_compiler.jar
jalviewjs_j2s_closure_stdout = j2s-closure.out
jalviewjs_j2s_closure_stdout = j2s-closure.out