Skip to content

Instantly share code, notes, and snippets.

@phillipsj
Created November 25, 2015 17:45
Show Gist options
  • Save phillipsj/75848d11d8d4a4ab091f to your computer and use it in GitHub Desktop.
Save phillipsj/75848d11d8d4a4ab091f to your computer and use it in GitHub Desktop.
Compile JSX using Web Compiler and CAKE
Task("CompileJSX")
.Does(() => {
var compilerConfigs = GetFiles("./src/Orchard.Web/Modules/**/compilerconfig.json");
foreach(var compilerConfig in compilerConfigs){
Information(string.Format("Compliing JSX for {0}.", compilerConfig.ToString()));
var webCompilerClean = new WebCompiler.CompilerCleanTask();
webCompilerClean.FileName = compilerConfig.ToString();
MSBuildTaskExecute(webCompilerClean);
var webCompilerBuild = new WebCompiler.CompilerBuildTask();
webCompilerBuild.FileName = compilerConfig.ToString();
MSBuildTaskExecute(webCompilerBuild);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment