Summary: | Mime type for .rhtml files | ||
---|---|---|---|
Product: | shared-mime-info | Reporter: | Johan Tibell <johan.tibell> |
Component: | freedesktop.org.xml | Assignee: | Shared Mime Info group <shared_mime_info> |
Status: | RESOLVED MOVED | QA Contact: | |
Severity: | enhancement | ||
Priority: | medium | CC: | bugzilla, dean |
Version: | unspecified | ||
Hardware: | x86 (IA32) | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
Johan Tibell
2006-04-12 23:51:01 UTC
Can you show where this type of files could be used? How would we detect those files? Is there an existing mime-type for those? I doubt it is possible to detect the mime-type with a fixed look-ahead into the file since you are not guaranteed (and not always likely) to run into both XHTML and Ruby code in a fixed number of steps. The only way I know of is using the file suffix. The mime-type would be useful since IDEs such as RadRails and others that provide syntax highlighting and editing could be registered as handlers for the mime-type. The file itself is used for web templating, i.e. the Ruby code in it is run and replaced by XHTML (much like a PHP file with mixed XHMTL and PHP). I'm not sure if there exist a widely used mime-type yet. application/x-httpd-eruby is the mime type I've seen usually used, (eruby is a ruby processing system for in-lined code, rails uses a different processor called erb iirc) it's included in /etc/mime.types (mime-support) package in Ubuntu 6.06. Please follow the instructions at: http://cgit.freedesktop.org/xdg/shared-mime-info/tree/HACKING#n31 for mime-type additions. -- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xdg/shared-mime-info/issues/41. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.