carrierwave
https://github.com/carrierwaveuploader/carrierwave
Ruby
Classier solution for file uploads for Rails, Sinatra and other Ruby web frameworks
CarrierWave::Storage::File#store!
Move the file to the uploader's store path. By default, store!() uses copy_to(), which operates by copying the file from the cache to the store, then deleting the file from the cache. If move_to_store() is overriden to return true, then store!() uses move_to(), which simply moves the file from cache to store. Useful for large files. === Parameters [file (CarrierWave::SanitizedFile)] the file to store === Returns [CarrierWave::SanitizedFile] a sanitized file
Edit
git clone [email protected]:carrierwaveuploader/carrierwave.git
cd carrierwave
open lib/carrierwave/storage/file.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-CarrierWave--Storage--File-store--for-pr
# Commit to gitgit add lib/carrierwave/storage/file.rbgit commit -m "better docs for CarrierWave::Storage::File#store!"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-CarrierWave--Storage--File-store--for-pr
hub pull-request
# Celebrate!