开发者

Microsoft Ajax Minifier 4, how to change output folder?

I would like to change the output folder of the ajax minifier so that when i build my project, all javascripts end up in the output folder instead of a copy next to the original file.

<Import Project="$(MSBuildExtensionsPath)\Microsoft\MicrosoftAjax\ajaxmin.tasks" />
<Target Name="AfterBuild">
    <ItemGroup>
        <JS Include="Sou开发者_JAVA技巧rceScripts\*.js" />  <!--Output="Scripts\*.js"-->
    </ItemGroup>
    <ItemGroup>
        <CSS Include="**\*.css" Exclude="**\*.min.css" />
    </ItemGroup>
    <AjaxMin
            JsSourceFiles="@(JS)"  JsSourceExtensionPattern="\.js$" JsTargetExtension=".min.js"
            CssSourceFiles="@(CSS)" CssSourceExtensionPattern="\.css$" CssTargetExtension=".min.css"  />
</Target>

Something like this. I have one folder called SourceScripts and one mirrored folder called Scripts. When i build, i want the scripts in SourceScripts (and its folders) to be minified and copied to the Scripts folder (same folder structure). Is this possible? We are using VS 2010.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜