I have a task with this defined
class mytask {
@OutputDirectory
File getDocDir() {
def typeString = type.toString().toLowerCase()
return new File(project.buildDir, "docs/${typeString}/${project.name}-sphinx-${typeString}")
}
}
Then, elsewhere in my code base, I have an action defined like this
static class PackageDocumentationAction implements Action<Tar> {
private final mytask documentationTask
PackageDocumentationAction(mytask documentationTask) {
this.documentationTask = documentationTask
println(this.documentationTask.docDir)
}
@Override
void execute(Tar tar) {
tar.compression = Compression.GZIP
tar.baseName = tar.project.name
tar.classifier = 'docs-' + documentationTask.type.builderName
tar.extension = 'tar.gz'
tar.from(documentationTask)
tar.into("${tar.getBaseName()}-${tar.getVersion()}-${tar.getClassifier()}")
}
}
Now, the mytask runs perfectly, no problems there. but, when i try to run the TAR, i get nothing but NO-SOURCE
i have tried doing the tar.source
to no avail. Whats wrong with this picture?