From 393c819f090b56b247b99f9a9d3b7b25c27fe25a Mon Sep 17 00:00:00 2001 From: silasb Date: Mon, 30 Sep 2013 15:01:03 -0400 Subject: [PATCH 1/2] Generating the MD5 fingerprint for the font files --- .../stylesheets/twitter/bootstrap/_glyphicons.scss | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/assets/stylesheets/twitter/bootstrap/_glyphicons.scss b/app/assets/stylesheets/twitter/bootstrap/_glyphicons.scss index d7c65e19..4c1dd43d 100644 --- a/app/assets/stylesheets/twitter/bootstrap/_glyphicons.scss +++ b/app/assets/stylesheets/twitter/bootstrap/_glyphicons.scss @@ -10,11 +10,11 @@ // Import the fonts @font-face { font-family: 'Glyphicons Halflings'; - src: font-url('#{$icon-font-path}#{$icon-font-name}.eot'); - src: font-url('#{$icon-font-path}#{$icon-font-name}.eot?#iefix') format('embedded-opentype'), - font-url('#{$icon-font-path}#{$icon-font-name}.woff') format('woff'), - font-url('#{$icon-font-path}#{$icon-font-name}.ttf') format('truetype'), - font-url('#{$icon-font-path}#{$icon-font-name}.svg#glyphicons-halflingsregular') format('svg'); + src: url(asset_path('#{$icon-font-path}#{$icon-font-name}.eot')); + src: url(asset_path('#{$icon-font-path}#{$icon-font-name}.eot?#iefix')) format('embedded-opentype'), + url(asset_path('#{$icon-font-path}#{$icon-font-name}.woff')) format('woff'), + url(asset_path('#{$icon-font-path}#{$icon-font-name}.ttf')) format('truetype'), + url(asset_path('#{$icon-font-path}#{$icon-font-name}.svg#glyphicons-halflingsregular')) format('svg'); } // Catchall baseclass From 0d959c1a8233ad96d45f7bf990508831729a3361 Mon Sep 17 00:00:00 2001 From: silasb Date: Mon, 30 Sep 2013 15:27:21 -0400 Subject: [PATCH 2/2] Fixing twitter:icons generate md5 fingerprint method --- Rakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Rakefile b/Rakefile index 68de8f27..1ee2e152 100644 --- a/Rakefile +++ b/Rakefile @@ -56,7 +56,7 @@ namespace :twitter do icons_path = 'app/assets/stylesheets/twitter/bootstrap/_glyphicons.scss' icons = File.read icons_path - icons.gsub!(/url\(/, "font-url(") + icons.gsub!(/url\((.*)\)/, 'url(asset_path(\1))') File.write(icons_path, icons) end