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

Additional mime types for fonts, coffescript and air #6

Closed
Soleone opened this issue Nov 1, 2011 · 3 comments
Closed

Additional mime types for fonts, coffescript and air #6

Soleone opened this issue Nov 1, 2011 · 3 comments

Comments

@Soleone
Copy link

Soleone commented Nov 1, 2011

We're currently using mime-types in our app and added the following additional content types:

MIME::Type.new('text/x-coffeescript') do |t|
  t.extensions = %w(coffee)
  t.encoding   = '8bit'
end,

MIME::Type.new('application/x-font-truetype') do |t|
  t.extensions  = %w(ttf)
  t.encoding    = 'base64'
end,

MIME::Type.new('application/x-woff') do |t|
  t.extensions  = %w(woff)
  t.encoding    = 'base64'
end

MIME::Type.new('application/vnd.adobe.air-applicationinstaller-package+zip') do |t|
  t.extensions  = %w(air)
  t.encoding    = 'base64'
end

I think those make sense to add as a default, but I wanted to make sure you agree before I go ahead and create/send a pull request.

@halostatue
Copy link
Member

x-woff should probably be x-font-woff. If your'e adding ttf, you should probably add otf as application/x-font-opentype.

application/font-woff is legitimate: http://www.w3.org/TR/WOFF/#appendix-b, but I'm not sure where to put it in the files (I'm trying to go as much as possible with the IANA registered type list).

Maybe we should create an applications.w3c file in lib/mime/types that contains additional types found here: http://www.w3.org/2002/06/registering-mediatype.html

@halostatue
Copy link
Member

Adding in 1.18.

@Soleone
Copy link
Author

Soleone commented Mar 21, 2012

👍 thanks

jperkin pushed a commit to TritonDataCenter/pkgsrc-legacy that referenced this issue Dec 9, 2013
== MIME::Types 1.18 / 2012-03-20
* New MIME Types:
  * Types reported in Issue #6
    (mime-types/ruby-mime-types#6):
    * CoffeeScript (text/x-coffeescript; .coffee; 8bit).
    * AIR
      (application/vnd.adobe.air-applicationinstaller-package+zip, .air;
      base64).
    * WOFF (application/font-woff; .woff; base64).
    * TrueType (application/x-font-truetype; .ttf; base64).
    * OpenType (application/x-font-opentype; .otf; base64).
  * WebM (audio/webm, video/webm; .webm). Issue #11
    (mime-types/ruby-mime-types#11).
* New extensions:
  * f4v/f4p (video/mp4, used by Adobe); f4a/fb4 (audio/mp4, used by Adobe).
* Bug Fixes:
  * It was pointed out that Licence.txt was incorrectly named. Fixed by
    renaming to Licence.rdoc (from Issue/Pull Request #8,
    mime-types/ruby-mime-types#8).
  * It was pointed out that a plan to have the test output generated
    automatically never went through. Issue #10
    (mime-types/ruby-mime-types#10)
jsonn pushed a commit to jsonn/pkgsrc that referenced this issue Oct 11, 2014
== MIME::Types 1.18 / 2012-03-20
* New MIME Types:
  * Types reported in Issue #6
    (mime-types/ruby-mime-types#6):
    * CoffeeScript (text/x-coffeescript; .coffee; 8bit).
    * AIR
      (application/vnd.adobe.air-applicationinstaller-package+zip, .air;
      base64).
    * WOFF (application/font-woff; .woff; base64).
    * TrueType (application/x-font-truetype; .ttf; base64).
    * OpenType (application/x-font-opentype; .otf; base64).
  * WebM (audio/webm, video/webm; .webm). Issue #11
    (mime-types/ruby-mime-types#11).
* New extensions:
  * f4v/f4p (video/mp4, used by Adobe); f4a/fb4 (audio/mp4, used by Adobe).
* Bug Fixes:
  * It was pointed out that Licence.txt was incorrectly named. Fixed by
    renaming to Licence.rdoc (from Issue/Pull Request #8,
    mime-types/ruby-mime-types#8).
  * It was pointed out that a plan to have the test output generated
    automatically never went through. Issue #10
    (mime-types/ruby-mime-types#10)
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

2 participants