Skip to content

Instantly share code, notes, and snippets.

@sroebuck
Created September 30, 2011 18:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sroebuck/1254516 to your computer and use it in GitHub Desktop.
Save sroebuck/1254516 to your computer and use it in GitHub Desktop.
Combining xsbt-webapp-plugin with coffeescripted-sbt plugin
// For the xsbt-web plugin...
seq(com.github.siasia.WebPlugin.webSettings :_*)
// Add an additional webappResources directory in the target directory...
webappResources <<= (webappResources, target in Compile)((wr, t) => wr +++ t / "webapp_managed" )
// For the CoffeeScripted Sbt plugin...
seq(coffeescript.CoffeeScript.coffeeSettings: _*)
// Use the additional webappResources directory as the targetDirectory for coffee...
(targetDirectory in Coffee) <<= (target in Compile)(t => t / "webapp_managed" / "js")
@sroebuck
Copy link
Author

This seems to work as a way of using the CoffeeScipted-sbt plugin to generate js files and then have them placed in the right location in the webapp by the xsbt-web-plugin.

Note: This was using xsbt-web-plugin 0.1.2. The 0.2.* series of xsbt-web-plugin changes the syntax of the above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment