search for: sprockets

Displaying 20 results from an estimated 55 matches for "sprockets".

2011 Oct 25
0
Sprocket Digest + Debug combination broken?
Hi all, we''re just in the process of upgrading to the new asset pipeline, but I''m having an annoying issue with Sprockets. It turns out that I can''t enable both *debug* and *digest* in development mode. When I do, I get a Errno::ENAMETOOLONG because the digest becomes the *entire* *content* of the file instead of a hex. I get this with both sass and javascript. Anyone have any idea what I''m doin...
2011 Sep 28
3
Error : bundle install
c:proj/proj1> bundle install Fetching source index for http://rubygems.org/ Could not find sprockets-2.0.0.beta.10 in any of the sources C:proj/proj1> C:proj/proj1>gem install sprockets -v=2.0.0.beta.10 ERROR: Could not find a valid gem ''sprockets'' (= 2.0.0.beta.10) in any reposito ry ERROR: Possible alternatives: sprockets C:proj/proj1>gem install sprockets Succes...
2012 Dec 18
2
cache-busting non-digest assets in sprockets in development a good idea? should headers in sprockets be configurable?
Just monkey patched Sprockets in our Rails 3.2.9 app to override the Cache-Control header for html assets that we need to tweak more often in development, but that we don''t want to use digests/fingerprinting with: # Sprockets 2.x patch if Rails.env.development? module Sprockets module Server private...
2011 Dec 05
9
jquery - word is not defined
Just starting out with a beginner book on jquery and the very first thing I am trying fails (has to be me) Rails 3.1 - other jquery things working including a poor example of drag & drop that is my ultimate target here but just simply trying to get every alternating row in a table to have a different css class So I''m using... app/assets/javascripts/people.js.coffee and put in...
2010 Feb 11
3
Parameterized ActiveRecord Associations: Any such thing?
...ard associations (has_many specifically). I''m wondering if such a thing exists or, if not, if anyone else has an elegant, equivalent solution? Example: class Sprocket < ActiveRecord::Base belongs_to :widget belongs_to :version end class Widget < ActiveRecord::Base has_many :sprockets has_many :versioned_sprockets, lambda do |v| :conditions => { :version => v } end end The idea behind the example is so I can do stuff like: def get_just_the_sprockets_i_need(callers_conditions) version = Version.find(magic_method_returning_just_the_right_id) widget = some_other...
2012 May 07
1
Sprockets, JST, Eco and escaping
While it was a good move from Rails part to escape ERB <%= %> tags by default, it doesn''t seem to happen to Sprockets as well. The strange bit is that according to Sprockets documentation, it would be just a matter of naming your template as .jst.eco to enable Eco: https://github.com/sstephenson/sprockets#javascript-templating-with-ejs-and-eco Then, extracted from Eco documentation: https://github.com/sstephe...
2011 Nov 10
1
url helper in model.js.erb.cofee (Sprockets::Context)
...to use a url helper inside this file if write .. url: ''<%= url_for(:action => :index) %>'' I get an error: NoMethodError Exception: undefined method `url_for'' for #<#<Class: 0xbdbb068>:0xeed1eb8> >>self.class #<Class:0xbdbb068> < Sprockets::Context How do I make url_for accessible in Sprockets::Context? thank you. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org...
2011 Aug 25
2
Problem with rails generaterspec:install, Error-Message: no such file to load, sprockets-railtie (loadError)
...and try to install rspec. But everytime when I try to use "rails g rspec:install" I get this error message: C:\Sites\rails\rails_projects\sample_appp>rails g rspec:install C:/Sites/rails/rails_projects/sample_appp/config/application.rb:8:in `require'': no such file to load -- sprockets/railtie (LoadError) from C:/Sites/rails/rails_projects/sample_appp/config/ application.rb:8:i n `<top (required)>'' from C:/RailsInstaller/Ruby1.9.2/lib/ruby/gems/1.9.1/gems/ railties-3.0.9 /lib/rails/commands.rb:15:in `require'' from C:/RailsInstaller/...
2011 Sep 01
7
couldn't find file 'jquery' rails 3.1 stable mountable engine
...ce it can''t fine jQuery. The jquery-rails gem is installed. I have jquery as a dependency in my gemspec file. I''ve even added an Gemfile to the dummy app just to try, but it gives the same error. accessing the dummy app ---------------------------------------------------------- Sprockets::FileNotFound in Root#index couldn''t find file ''jquery'' (in /Webapps/coffee/test/dummy/app/assets/javascripts/application.js:7) Started GET "/" for 127.0.0.1 at 2011-09-01 20:31:01 +0200 Processing by RootController#index as HTML Rendered root/index.html.erb...
2011 Jul 22
0
Asset Pipeline and Sprockets
Ok I would love to work out how to use the new Raisl 3.1 Asset Pipeline with SCSS variables, mixins etc and being able to use the asset_path tag. What I have so far is this. Im my application.css.scss I have the following. *= require_self *= require layout *= require home This works fine with using the asset_path helper and variable within layout ie, // layout.css.scss.erb
2011 Nov 25
4
Sprockets File not Found Exception.
Hi Everyone, I was trying out some sample applications for Rails. I created some controllers and pages. But when i try to access one of them i get an exception on the webpage: --------------------------------------------------------------------- Sprockets::FileNotFound in Pages#home Showing c:/railscode/test_app/app/views/layouts/application.html.erb where line #6 raised: couldn''t find file ''jquery'' (in c:/railscode/test_app/app/assets/javascripts/application.js:7) Extracted source (around line #6): 3: <head> 4:...
2011 Nov 14
0
Rails 3.1.2.rc2
...3.1.2.rc2 has been released. Dont ask about rc1! Please give it a try, but first read the important note below. If there are no release blockers, then I will be releasing the final version some time after 16:00 UTC on 17th November. ## IMPORTANT NOTE FOR RC TESTERS ## Rails 3.1.2 will depend on sprockets 2.1. The current stable version of sass-rails (3.1.4) depends on sprockets 2.0. To solve this problem, the current sass-rails release candidate removes its explicit dependency on sprockets, because sass-rails depends on actionpack which already depends on sprockets, so the version should be specifi...
2013 Feb 27
4
My SCSS compiled CSS lacks "/assets" in the generated urls
Running "rake assets:clobber assets:precompile" will generate files like "application-xxx.css" with incorrect urls after upgrading to Rails 4. For example url(/fields/xxx.png) when it should be url(/assets/fields/xxx.png). For some unknown reason it worked once in development mode, but after running rake assets:clobber I can''t get it to work again... Any ideas
2012 Sep 10
4
Rails error: invalid byte sequence in UTF-8
Hello, i have a app on rails 3.2.1 and i use a jquery lib called jQuery Timelinr 0.9.5: http://www.csslab.cl/2011/08/18/jquery-timelinr/ but, when i use it on a .erb view, i got a error: Showing * /home/carlos.ribeiro/projetos/amarribo/app/views/conheca/historico.html.erb* where line *#59* raised: invalid byte sequence in UTF-8 Extracted source (around line *#59*): 57: 58: <%=
2006 Mar 29
4
Scaffold generator: create vs. new
...scaffold generator produces? I run: > script/generate scaffold modelname controllername And now I need to do some work inside the controllername.rb file. For example, pulling a list from another database table to supply for a drop-down select in the "create a new whatsit" form. @sprockets = Sprocket.find(:all) Do I put this in new or create? Why? I''ve been floundering around on this for some time, and I''ve not been confident that what I''m doing is the right way, is efficient as far as programmer hours, or will scale correctly in production. Thanks a...
2012 Mar 29
25
Unable to deploy to Apache
Hi All, Can someone please help? I''ve been banging my head against for wall for 2 months; all of which has been spent trying to set up ROR. So I actually haven''t written 1 line of code :( Any help would be greatly appreciated :) I''m following the 4th edition of "Agile Web Development with Rails". So, I''m able to deploy the site via WEBrick.
2014 Apr 26
0
jquery_ujs.js 404
...s 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 // compiled file. // // Read Sprockets README (https://github.com/sstephenson/sprockets#sprockets-directives) for details // about supported directives. // //= require jquery //= require jquery_ujs //= require turbolinks //= require_tree . this is my production Kopy2::Application.configure do # Settings specified here will take prece...
2011 Aug 25
1
Devise + Forem: undefined method weeks on Fixnum
...loaded by the time Devise is calling out to them, but I don''t know why this would be the case. My Gemfile looks like: source ''http://rubygems.org'' # Forem requirements: gem ''rails'', :git => "git://github.com/rails/rails.git" gem ''sprockets'', :git => "git://github.com/sstephenson/sprockets" gem ''forem'', :git => "git://github.com/radar/forem.git" # gem ''rails'', ''3.0.9'' gem ''devise'' ... I was using Rails 3.0.9 previously and it w...
2012 Apr 30
0
Rails 3.1.3 -> 3.2.3 upgrade, assets can't be found
...9;'ve investigated for several hours and it seems that the root of the problem is that the order of initializers becomes wrong after initializers.tsort (in railties-3.2.3/lib/rails/ initializable.rb:54). It seems that finisher_hook initializer (which runs after_initialize, which then bootstraps sprockets by copying paths from config.assets.paths to Rails.application.assets.paths) is run before append_assets_path (which loads asset paths from all engines) and so Sprockets is bootstrapped with empty list of asset paths. Maybe anyone has any ideas where could the problem be and how to solve it? -- Y...
2014 Mar 19
0
ActionView::Template::Error: end of file reached Rails 4.0.4
...4.0. On my CI environment, I'm getting "ActionView::Template::Error: end of file reached" randomly in different controller specs pointing to a view in which I have "javascript_include_tag 'application'". Has anyone seen this before? Relevant gems: rails (4.0.4) sprockets (2.11.0) sprockets-rails (2.0.1) sass-rails (4.0.2) coffee-rails (4.0.1) -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscr...