carrierwave

https://github.com/carrierwaveuploader/carrierwave

Ruby

Classier solution for file uploads for Rails, Sinatra and other Ruby web frameworks

CarrierWave::Uploader::Configuration::ClassMethods#cache_storage

Sets the cache storage engine to be used when storing cache files with this uploader.
Same as .storage except for required methods being #cache!(CarrierWave::SanitizedFile),
#retrieve_from_cache! and #delete_dir!.

=== Parameters

[storage (Symbol, Class)] The cache storage engine to use for this uploader

=== Returns

[Class] the cache storage engine to be used with this uploader

=== Examples

    cache_storage :file
    cache_storage CarrierWave::Storage::File
    cache_storage MyCustomStorageEngine

Source | Google | Stack overflow

Edit

git clone [email protected]:carrierwaveuploader/carrierwave.git

cd carrierwave

open lib/carrierwave/uploader/configuration.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-CarrierWave--Uploader--Configuration--ClassMethods-cache_storage-for-pr


# Commit to git

git add lib/carrierwave/uploader/configuration.rbgit commit -m "better docs for CarrierWave::Uploader::Configuration::ClassMethods#cache_storage"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-CarrierWave--Uploader--Configuration--ClassMethods-cache_storage-for-pr

hub pull-request


# Celebrate!