Environment specific variables in sprokcets
===

I'm use Rails 3.2 built in sprockets functionality to compile static assets. Is it possible to compile javascript with environment specific variables?

So I would like to do something like this

/assets/javascripts/myfile.js

------------------------------
    
     //lots of code
     script.src =
            ('https:' == document.location.protocol ? 'https://' : 'http://') +
                    'some.metrics.site/projects/<%=ENV_SPECIFIC_TOKEN%>.js';
      //lots of other code