title: "rake assets:precompile" gives punc error
body: <p>I'm trying to precompile my assets for production, but rails doesn't seem to be cooperating.</p>
  
  <pre><code>$ bundle exec rake assets:precompile
  /home/drderp/.rvm/rubies/ruby-1.9.3-p194/bin/ruby /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
  rake aborted!
  Unexpected token punc, expected punc (line: 213, col: 13, pos: 5986)
  
  Error
      at new JS_Parse_Error (&lt;eval&gt;:1720:22)
      at js_error (&lt;eval&gt;:1728:15)
      at croak (&lt;eval&gt;:2189:17)
      at token_error (&lt;eval&gt;:2196:17)
      at expect_token (&lt;eval&gt;:2209:17)
      at Object.expect (&lt;eval&gt;:2212:40)
      at Object.1 (&lt;eval&gt;:2763:38)
      at prog1 (&lt;eval&gt;:2770:28)
      at &lt;eval&gt;:2560:51
      at maybe_unary (&lt;eval&gt;:2665:27)
    (in /home/drderp/projects/p/app/assets/javascripts/application.js)
  
  Tasks: TOP =&gt; assets:precompile:primary
  (See full trace by running task with --trace)
  rake aborted!
  Command failed with status (1): [/home/drderp/.rvm/rubies/ruby-1.9.3-p194/b...]
  
  Tasks: TOP =&gt; assets:precompile
  (See full trace by running task with --trace)
  </code></pre>
  
  <p>This is the entire contents of application.js:</p>
  
  <pre><code>// This is a manifest file that'll be compiled into application.js, which will include all the files
  // listed below.
  //
  // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
  // or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
  //
  // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
  // the compiled file.
  //
  // Since javascript, no matter what order you load it in, executes in different order, it doesn't
  // matter
  //
  // WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD
  // GO AFTER THE REQUIRES BELOW.
  //
  //= require jquery
  </code></pre>
  
  <p>Rails version 3.2.8, running on Ruby 1.9.3.</p>
  
  <p><strong>edit</strong>:</p>
  
  <p>Here's <code>bundle exec rake assets:precompile --trace</code>, as requested:</p>
  
  <pre><code>$ bundle exec rake assets:precompile --trace
  ** Invoke assets:precompile (first_time)
  ** Execute assets:precompile
  /home/drderp/.rvm/rubies/ruby-1.9.3-p194/bin/ruby /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets --trace
  ** Invoke assets:precompile:all (first_time)
  ** Execute assets:precompile:all
  ** Invoke assets:precompile:primary (first_time)
  ** Invoke assets:environment (first_time)
  ** Execute assets:environment
  ** Invoke environment (first_time)
  ** Execute environment
  ** Invoke tmp:cache:clear (first_time)
  ** Execute tmp:cache:clear
  ** Execute assets:precompile:primary
  rake aborted!
  Unexpected token punc, expected punc (line: 213, col: 13, pos: 5986)
  
  Error
      at new JS_Parse_Error (&lt;eval&gt;:1720:22)
      at js_error (&lt;eval&gt;:1728:15)
      at croak (&lt;eval&gt;:2189:17)
      at token_error (&lt;eval&gt;:2196:17)
      at expect_token (&lt;eval&gt;:2209:17)
      at Object.expect (&lt;eval&gt;:2212:40)
      at Object.1 (&lt;eval&gt;:2763:38)
      at prog1 (&lt;eval&gt;:2770:28)
      at &lt;eval&gt;:2560:51
      at maybe_unary (&lt;eval&gt;:2665:27)
    (in /home/drderp/projects/p/app/assets/javascripts/application.js)
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/execjs-1.4.0/lib/execjs/ruby_racer_runtime.rb:34:in `rescue in block in eval'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/execjs-1.4.0/lib/execjs/ruby_racer_runtime.rb:28:in `block in eval'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/execjs-1.4.0/lib/execjs/ruby_racer_runtime.rb:80:in `block in lock'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/therubyracer-0.10.2/lib/v8/c/locker.rb:13:in `Locker'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/execjs-1.4.0/lib/execjs/ruby_racer_runtime.rb:78:in `lock'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/execjs-1.4.0/lib/execjs/ruby_racer_runtime.rb:27:in `eval'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/execjs-1.4.0/lib/execjs/ruby_racer_runtime.rb:19:in `exec'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/uglifier-1.3.0/lib/uglifier.rb:100:in `compile'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/compressors.rb:74:in `compress'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/processing.rb:265:in `block in js_compressor='
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/processor.rb:29:in `call'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/processor.rb:29:in `evaluate'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/tilt-1.3.3/lib/tilt/template.rb:76:in `render'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/context.rb:177:in `block in evaluate'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/context.rb:174:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/context.rb:174:in `evaluate'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/bundled_asset.rb:26:in `initialize'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:244:in `new'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:244:in `build_asset'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/index.rb:89:in `block in build_asset'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/caching.rb:19:in `cache_asset'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/index.rb:88:in `build_asset'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:163:in `find_asset'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/index.rb:56:in `find_asset'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/static_compiler.rb:23:in `block in compile'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:212:in `block in each_logical_path'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:200:in `block (2 levels) in each_file'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:190:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:190:in `each_entry'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:198:in `block in each_file'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:197:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:197:in `each_file'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/sprockets-2.1.3/lib/sprockets/base.rb:210:in `each_logical_path'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/static_compiler.rb:18:in `compile'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/assets.rake:56:in `internal_precompile'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/assets.rake:70:in `block (3 levels) in &lt;top (required)&gt;'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `call'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `block in execute'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `execute'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:158:in `block in invoke_with_call_chain'
  /home/drderp/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:in `invoke_with_call_chain'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:144:in `invoke'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/assets.rake:60:in `block (3 levels) in &lt;top (required)&gt;'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `call'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `block in execute'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `execute'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:158:in `block in invoke_with_call_chain'
  /home/drderp/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:in `invoke_with_call_chain'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:144:in `invoke'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:116:in `invoke_task'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block (2 levels) in top_level'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block in top_level'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:88:in `top_level'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:66:in `block in run'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/bin/rake:33:in `&lt;top (required)&gt;'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in `load'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in `&lt;main&gt;'
  Tasks: TOP =&gt; assets:precompile:primary
  rake aborted!
  Command failed with status (1): [/home/drderp/.rvm/rubies/ruby-1.9.3-p194/b...]
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/file_utils.rb:53:in `block in create_shell_runner'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/file_utils.rb:45:in `call'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/file_utils.rb:45:in `sh'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/file_utils_ext.rb:39:in `sh'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/file_utils.rb:80:in `ruby'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/file_utils_ext.rb:39:in `ruby'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/assets.rake:12:in `ruby_rake_task'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/assets.rake:21:in `invoke_or_reboot_rake_task'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.8/lib/sprockets/assets.rake:29:in `block (2 levels) in &lt;top (required)&gt;'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `call'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `block in execute'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `execute'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:158:in `block in invoke_with_call_chain'
  /home/drderp/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:in `invoke_with_call_chain'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:144:in `invoke'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:116:in `invoke_task'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block (2 levels) in top_level'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `each'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block in top_level'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:88:in `top_level'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:66:in `block in run'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/bin/rake:33:in `&lt;top (required)&gt;'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in `load'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in `&lt;main&gt;'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `eval'
  /home/drderp/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `&lt;main&gt;'
  Tasks: TOP =&gt; assets:precompile
  </code></pre>