answer:First, I should say that I am not familiar with Rails, so take this as generic advice: Without that unless, the file would get recreated every time. This would be a very bad idea, as you could have one get rewriting the file at the same time another get is trying to read it (I’m assuming that this function is called on every request). What you need is additional logic to detect if it needs to be regenerated due to changes in other files. A simple but inefficient way is to compare timestamps of your source files with the all.cs and all.js files.