apply plugin: 'java'
// tag::use-plugin[]
apply plugin: 'application'
// end::use-plugin[]

version = '1.0.2'

// tag::mainClassName-conf[]
mainClassName = "org.gradle.sample.Main"
// end::mainClassName-conf[]

// tag::application-defaultjvmargs[]
applicationDefaultJvmArgs = ["-Dgreeting.language=en"]
// end::application-defaultjvmargs[]

// tag::executableDir-conf[]
executableDir = "custom_bin_dir"
// end::executableDir-conf[]

// tag::distribution-spec[]
task createDocs {
    def docs = file("$buildDir/docs")
    outputs.dir docs
    doLast {
        docs.mkdirs()
        new File(docs, "readme.txt").write("Read me!")
    }
}

distributions {
    main {
        contents {
            from(createDocs) {
                into "docs"
            }
        }
    }
}
// end::distribution-spec[]

repositories {
    mavenCentral()
}

dependencies {
    compile 'commons-collections:commons-collections:3.2.2'
}
