mytardis/mytardis — pull request #251 by crawley (2013-05-03 07:19:59+00:00)
Title: Mac zip disable (not ready to pull yet!)

This pull request adds functionality to detect that the user is running on a Mac, and not offer the "download as ZIP" option. It uses django-user-agent (and dependent stuff) to do the hard work.

There are two things I want to check with folks before this is merged. Both are in the changes to "tardis/settings_changeme.py"
1. There is currently a bug in the ua_parser code that is causing it to not find the default "regexes.yaml" file in the egg. So I've copied that file into mytardis, and used a settings hack to tell ua_parser where to find it. (Ick ... but there's a pull request against ua_parser to fix this ...)
2. I've tried to make this functionality "optional" but the problem is that to enable it you need to add a middleware class and django app. I've done this in a clunky way ... by providing "instructions". Topic for discussion: can we come up with a better way to do this kind of thing?