nikhilk/scriptsharp — Issue #151: Control over generated file names
Author: elkdanger
Created: 2012-02-24 08:12:21+00:00
State: open

Is there a way we could potentially have control over the file names that are generated from Script# libraries, for both the minified and debug files?

Imagine I have a Script# project simply called 'Scripts'; the files which are currently generated are called 'Scripts.debug.js' and 'Scripts.js' for the debug and minified versions respectively.

In order to play nicely with the new Asp.Net MVC 4 Bundling support, and to bring it inline with convention, it would be nicer if we could somehow specify that the debug and minified files were actually called 'scripts.js' and 'scripts.min.js' respectively.

I could imagine that we might do this through the Project file by using a couple of keys and macros, for example:

```xml
${ScriptName}.js
${ScriptName}.min.js
```
Or something to that effect.

The reason I've mentioned Bundling is because it has some interesting behaviours regarding how it treats files with 'conventional' file names (I've outlined this in [a blog post](http://stevescodingblog.co.uk/asp-net-bundling-minification-and-convention/)). It will automatically favour .min files when bundling a directory, but also actually completely ignores files with a .debug.js extension, which means we would never be able to implement a custom minifier (should we happen to require one).