Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Digests for precompiled assets #54

Open
idearise opened this issue Apr 25, 2012 · 10 comments
Open

Digests for precompiled assets #54

idearise opened this issue Apr 25, 2012 · 10 comments

Comments

@idearise
Copy link

It looks like the helpers (ex: theme_stylesheet_link_tag) are not returning asset digest urls for assets, although the digest versions are available.

For example:

<%= theme_stylesheet_link_tag "application" =%>

returns the following (no digest):

<link href="/assets/themename/stylesheets/application.css" media="screen" rel="stylesheet" type="text/css" />
@idearise
Copy link
Author

This might help with obtaining the digest file names...A hash containing keys of precompiled assets with the values of their digest filenames is available through:

Rails.application.config.assets.digests

@lucasefe
Copy link
Owner

lucasefe commented Jun 2, 2012

Is this happening on production? I think the digest version is only generated on production.

@idearise
Copy link
Author

idearise commented Jun 4, 2012

Digest versions are available in any environment where digest URLs enabled ( config.assets.digest = true ).

@tkriplean
Copy link

I'm just gonna add that this happens for me too: theme_stylesheet_link_tag is not linking to the available digest version in production.

I'm running themes_for_rails (0.5.1) & rails (3.2.6).

Thanks for the great gem @lucasefe, it is one of my favorites :-)

@jasherai
Copy link

jasherai commented Aug 2, 2012

@idearise I see you have a fork which is making use of the digests. Are there any issues outstanding that need addressing? I was about to attack this issue in much the same way and was wondering if there was anything I could help with?

@lucasefe
Copy link
Owner

lucasefe commented Aug 2, 2012

@idearise And if so, why don't you do a Pull Request? Maybe w can merge it to master, man.

Thanks

jasherai added a commit to jasherai/themes_for_rails that referenced this issue Aug 9, 2012
* check for asset digest and store in TFR config

* If asset pipeline, use theme_assets_dir config and PREPEND to
config.asset.paths. This requires theme assets to be in a folder under
the theme_name so as not to clobber other themes.

* When gathering digested assets, fallback to the original asset if no
digested one is available
jasherai added a commit to jasherai/themes_for_rails that referenced this issue Aug 9, 2012
* Load and override action_view when asset digests are enabled.

* don't load asset_controller routes when asset pipeline is in use.
jasherai added a commit to jasherai/themes_for_rails that referenced this issue Aug 9, 2012
jasherai added a commit to jasherai/themes_for_rails that referenced this issue Aug 9, 2012
ksheurs pushed a commit to vhx/themes_for_rails that referenced this issue Aug 28, 2012
* check for asset digest and store in TFR config

* If asset pipeline, use theme_assets_dir config and PREPEND to
config.asset.paths. This requires theme assets to be in a folder under
the theme_name so as not to clobber other themes.

* When gathering digested assets, fallback to the original asset if no
digested one is available
ksheurs pushed a commit to vhx/themes_for_rails that referenced this issue Aug 28, 2012
* Load and override action_view when asset digests are enabled.

* don't load asset_controller routes when asset pipeline is in use.
ksheurs pushed a commit to vhx/themes_for_rails that referenced this issue Aug 28, 2012
@danbronsema
Copy link

Has this been pulled into the master? I'd love to get this working!

@sweetroll
Copy link

Would like to see this issue resolved too. Any chance of adding it in without @idearise pull request?

@ksheurs
Copy link

ksheurs commented Oct 10, 2012

hey all, i will try and get tests working soon so i can do a pull request. sorry for the delay...

@lucasefe
Copy link
Owner

Hey, everyone, I'm looking for a maintainer of this gem. I have no time to
dedicate to it, and I'm no longer using it, so if someone wants to step up,
I'll be glad to provide help and support for the transition.

I don't want this project to die because of my inability of keeping up with
the demand.

So, anyone is interested? If so, shoot me an email to lucasefe at gmail

Best

Lucas.

techieshark referenced this issue in dhedlund/calagator Jun 28, 2013
Removed some core assets (jquery, jquery-ui, formtastic) that are
automatically provided by gems; before the asset pipeline, assets had to be
copied across to the project directory by hand or via *:install rake tasks.

Removed some assets that didn't appear to be used by anything such as
reset-fonts-grids.css, jquery.dimensions.min.js.

[THEME] The 'reset' stylesheet was moved to core, it is unlikely you would
need or want to update this manually.  'common' and 'formtastic' core
stylesheets have been merged into the 'application' stylesheet.

  Change the following lines in themes/*/views/layouts/application.html.erb:
    <%= theme_stylesheet_link_tag 'reset', :media => :all %>
    <%= stylesheet_link_tag 'common', 'formtastic', :media => :all %>
  to look like:
    <%= stylesheet_link_tag 'application', :media => :all %>

Conflicts:
	app/assets/javascripts/jquery-ui.js
	app/assets/javascripts/jquery-ui.min.js
	app/assets/javascripts/jquery.js
	app/assets/javascripts/jquery.min.js
	app/assets/javascripts/jquery_ujs.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants