buildscript {
  repositories {
    maven { url uri('/tmp/repo') }
    mavenLocal()
    mavenCentral()
    maven { url "http://maven.restlet.org" }
  }

  dependencies {
    classpath group: 'org.docbook', name: 'docbook-xslt2', version: '2.3.0'
    classpath group: 'org.docbook', name: 'docbook-schemas', version: '5.1-1'
    classpath group: 'com.xmlcalabash', name: 'xmlcalabash', version: '1.1.18-98'
    classpath group: 'com.xmlcalabash', name: 'xmlcalabash1-gradle', version: '1.3.4'
    classpath group: 'org.xmlresolver', name: 'xmlresolver', version: '0.13.1'
  }
}

repositories {
  mavenLocal()
  mavenCentral()
}

import org.docbook.DocBookTask
import com.xmlcalabash.XMLCalabashTask

task helloWorld() {
  doFirst {
    println("Hello, world.")
  }
}

task testTask(type: XMLCalabashTask) {
  input("source", "input.xml")
  output("result", "output.xml")
  pipeline("pipeline.xpl")
}

task testDocBook(type: DocBookTask) {
  // catalogFile = "/tmp/cat.xml"
  debug = true
  uriResolver = "org.xmlresolver.Resolver"
  input("source", "input.xml")
  output("result", "output.html")
}
