On Sun, Jan 25, 2009 at 09:45:27PM +0000, Brian Candler wrote:
> On Sun, Jan 25, 2009 at 09:38:45PM +0000, Noah Slater wrote:
> > On Sun, Jan 25, 2009 at 09:06:22PM +0000, Brian Candler wrote:
> > > For now though, couchapp could use the ruby MIME::Types gem in place of
> > > its
> > > own hard-coded table.
> > >
> > > irb(main):008:0> MIME::Types.type_for('citydesk.xml').first.to_s
> > > => "application/xml"
> >
> > If Ruby is anything like Python, it pulls those values from /etc/mime.types
>
> Not the Ruby one. It has them all hardcoded direct from the RFCs, plus some
> metadata which /etc/mime.types doesn't include (for example, it notes which
> MIME types refer to digital signatures)
>
> I guess if the server did this, and did it properly, it would free up all
> the clients from having to worry about it.
Yep, this is what we want to do.
Apache httpd provides a way to configure this using regular configuration files,
but as this wouldn't comfortably fit into an ini format, we would do well to
just use a standard mime.types file and let users specify multiple ones. Merging
these files is easy as pie.
--
Noah Slater, http://tumbolia.org/nslater