diff options
author | Johannes Rudolph <johannes.rudolph@gmail.com> | 2013-10-24 00:04:18 +0200 |
---|---|---|
committer | Johannes Rudolph <johannes.rudolph@gmail.com> | 2013-10-24 00:04:18 +0200 |
commit | 40ab6337c2f84d85a80d150bf55f9e8a202adcc6 (patch) | |
tree | be6f39ece728017fdb091536742087176ff70627 /src/main/scala | |
parent | 8321f6b07be3de06059517465bea951acd2eae0a (diff) | |
download | sbt-boilerplate-40ab6337c2f84d85a80d150bf55f9e8a202adcc6.tar.gz sbt-boilerplate-40ab6337c2f84d85a80d150bf55f9e8a202adcc6.tar.bz2 sbt-boilerplate-40ab6337c2f84d85a80d150bf55f9e8a202adcc6.zip |
cross-build for sbt 0.13, fixes #80.5.1
Diffstat (limited to 'src/main/scala')
-rw-r--r-- | src/main/scala/spray/boilerplate/BoilerplatePlugin.scala | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/scala/spray/boilerplate/BoilerplatePlugin.scala b/src/main/scala/spray/boilerplate/BoilerplatePlugin.scala index 6049c98..149192c 100644 --- a/src/main/scala/spray/boilerplate/BoilerplatePlugin.scala +++ b/src/main/scala/spray/boilerplate/BoilerplatePlugin.scala @@ -38,7 +38,7 @@ object BoilerplatePlugin extends Plugin { def watch(sourceDirKey: SettingKey[File], filterKey: SettingKey[FileFilter], excludeKey: SettingKey[FileFilter]) = watchSources <++= (sourceDirKey, filterKey, excludeKey) map descendents def descendents(sourceDir: File, filt: FileFilter, excl: FileFilter) = - sourceDir.descendentsExcept(filt, excl).get + descendantsExcept(sourceDir, filt, excl).get def generateFromTemplates(streams: TaskStreams, sourceDir: File, targetDir: File): Seq[File] = { val files = sourceDir ** "*.template" @@ -65,4 +65,7 @@ object BoilerplatePlugin extends Plugin { mapping.map(_._2) } } + + def descendantsExcept(path: PathFinder, include: FileFilter, intermediateExclude: FileFilter): PathFinder = + (path ** include) --- (path ** intermediateExclude ** include) } |