Skip to content

Commit

Permalink
Improved generateSVGs task etc.
Browse files Browse the repository at this point in the history
  • Loading branch information
thvitt committed Sep 25, 2019
1 parent 350cb85 commit d88bedb
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 7 deletions.
24 changes: 18 additions & 6 deletions build.gradle
Expand Up @@ -4,8 +4,10 @@ plugins {
}


def architecture = "linux-x86_64" // TODO make adjustable
def toolDir = "$buildDir/tools"
ext.architecture = "linux-x86_64" // TODO make adjustable
ext.toolDir = "$buildDir/tools"
ext.dataDir = file('data', PathValidation.DIRECTORY)



group = 'net.faustedition'
Expand Down Expand Up @@ -50,8 +52,8 @@ dependencies {
implementation 'com.google.guava:guava-collections:r03'
implementation 'com.xmlcalabash:xmlcalabash:1.1.13-96'

tools 'slimerjs:slimerjs:1.0.0-beta.1@tar.bz2'
tools 'org.mozilla:firefox:57.0.4@tar.bz2'
tools 'slimerjs:slimerjs:1.0.0@tar.bz2'
tools 'org.mozilla:firefox:59.0@tar.bz2'

testCompile 'junit:junit:4.12'
}
Expand All @@ -68,15 +70,25 @@ task generateSVGs(type: JavaExec) {
dependsOn getTools
dependsOn classes

inputs.dir("$dataDir/xml/transcript")
outputs.dir("$buildDir/www/transcript")

environment 'LANG', 'en_US.UTF-8'
environment 'LC_ALL', 'en_US.UTF-8'
environment 'SLIMERJSLAUNCHER', "$toolDir/firefox/firefox"

systemProperties([
'phantomjs.binary': "$toolDir/slimerjs-1.0.0-beta.1/slimerjs",
])
'phantomjs.binary': "$toolDir/slimerjs-1.0.0/slimerjs" ,
'faust.diplo.target': buildDir
])
systemProperties(project.properties.findAll {key, value -> key.matches('^faust\\.diplo\\.')})

classpath sourceSets.main.runtimeClasspath
main 'net.faustedition.gen.DiplomaticConversion'
}
build.dependsOn generateSVGs


task showProps { doLast {
project.properties.each { key, value -> println "$key=$value"}
}}
8 changes: 8 additions & 0 deletions gradle.properties
@@ -0,0 +1,8 @@
org.gradle.jvmargs=-Xmx4G -XX:MaxPermSize=2G -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
org.gradle.parallel=true

upload.url=beta.faustedition.net:/var/www/dev
faust.diplo.allowedFailures=10
faust.diplo.port=0
faust.diplo.debug=0
exist.app-name=faust-dev
Expand Up @@ -60,7 +60,7 @@ public class DiplomaticConversion {
private static Logger logger = Logger.getLogger(DiplomaticConversion.class.getName());

public static Path root = Paths.get(System.getProperty("faust.diplo.root", "data/xml/"));
public static Path target = Paths.get("target");
public static Path target = Paths.get(System.getProperty("faust.diplo.target", "target"));

private static final Path prepared_svg = target.resolve(System.getProperty("faust.diplo.prepared-svg", "prepared-svg"));
public static Path profile = target.resolve("profile");
Expand Down

0 comments on commit d88bedb

Please sign in to comment.