dwilkie/carrierwave_direct — pull request #92 by jkamenik (2013-06-29 23:40:21+00:00)
Title: Default Content type

This is a correction of a previous pull request #52 which added content types but failed because not everyone forced a user to pick a content type so it would fail for them. This adjusts the default content type so that it is "binary/octet-stream" which is the default for amazon.

For rails we also add a form helper which allows a user to select a different content type.

There are two issues outstanding but I wanted to get this out to the community for comment:

1. I haven't had time to develop a reference app that uses gem and therefore proves that it works in practice. The project that first needed this gem is no longer compatible so I will have to start from scratch. If anyone out there could help confirm this before merging that would be great.
2. Travis CI breaks, but not my local machine. I have tried to debug but it doesn't fail for me, and the failure is not on a line that I modified. If anyone has any clues as to the issue I would love to fix this before it gets merged. Below is the traceback:

```bash
$ bundle exec rake
/home/travis/.rvm/rubies/ruby-1.9.3-p448/bin/ruby -S rspec ./spec/action_view_extensions/form_helper_spec.rb ./spec/form_builder_spec.rb ./spec/mount_spec.rb ./spec/orm/activerecord_spec.rb ./spec/orm/indirect_activerecord_spec.rb ./spec/test/capybara_helpers_spec.rb ./spec/test/helpers_spec.rb ./spec/uploader_spec.rb --color
/home/travis/build/jkamenik/carrierwave_direct/spec/support/form_builder_helpers.rb:16:in `': uninitialized constant FormBuilderHelpers::ActionController (NameError)
from /home/travis/build/jkamenik/carrierwave_direct/spec/support/form_builder_helpers.rb:11:in `'
from /home/travis/build/jkamenik/carrierwave_direct/spec/spec_helper.rb:9:in `require'
from /home/travis/build/jkamenik/carrierwave_direct/spec/spec_helper.rb:9:in `block in '
from /home/travis/build/jkamenik/carrierwave_direct/spec/spec_helper.rb:9:in `each'
from /home/travis/build/jkamenik/carrierwave_direct/spec/spec_helper.rb:9:in `'
from /home/travis/build/jkamenik/carrierwave_direct/spec/action_view_extensions/form_helper_spec.rb:3:in `require'
from /home/travis/build/jkamenik/carrierwave_direct/spec/action_view_extensions/form_helper_spec.rb:3:in `'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `load'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `block in load_spec_files'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `each'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `load_spec_files'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/command_line.rb:22:in `run'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/runner.rb:80:in `run'
from /home/travis/.rvm/gems/ruby-1.9.3-p448/gems/rspec-core-2.13.1/lib/rspec/core/runner.rb:17:in `block in autorun'
```